/* /assets/true_filtered.css */

/* ==========================================================================
   01. FARBPALETTE & BASIS-VARIABLEN
   ========================================================================== */
:root {
  --primary-blue: #00334e;
  --primary-gold: #d4af37;
  --bg-color: #f9f7f1;
  --text-color: #2c3e50;

  /* Dezente moderne Flächen */
  --surface-1: rgba(255, 255, 255, 0.82);
  --surface-2: rgba(248, 250, 252, 0.78);
  --surface-3: rgba(240, 246, 250, 0.70);
  --stroke: rgba(0, 51, 78, 0.10);
  --stroke-strong: rgba(0, 51, 78, 0.18);

  /* Schatten */
  --shadow-sm: 0 8px 22px rgba(10, 40, 60, 0.08);
  --shadow-md: 0 14px 34px rgba(10, 40, 60, 0.10);

  /* Abstand, damit die Autorencards nicht unter das schwebende Banner rutschen */
  --authors-grid-top: 78px;
}

/* ==========================================================================
   02. GLOBALE RESETS & GRUNDLAYOUT
   ========================================================================== */
html {
  overflow-x: hidden;
  width: 100%;
  max-width: 100%;
  -webkit-tap-highlight-color: transparent;
}

* {
  box-sizing: border-box; 
  -webkit-tap-highlight-color: transparent;
}

/* Wortumbruch für Texte */
.author-name, .book-item div, .suggestion-item, .author-link {
  overflow-wrap: break-word;
  word-wrap: break-word;
  hyphens: auto;
}

#modalTitle {
  padding-right: 35px; 
  word-break: normal; 
  overflow-wrap: break-word;
}

*:focus:not(:focus-visible) {
  outline: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
  -webkit-user-drag: none; 
}

body {
  margin: 0;
  padding: 20px;
  font-family: 'Acme', cursive;
  background-color: var(--bg-color);
  background-image:
    radial-gradient(1200px 600px at 10% 0%, rgba(212, 175, 55, 0.10), rgba(0, 0, 0, 0) 60%),
    radial-gradient(900px 500px at 90% 20%, rgba(0, 51, 78, 0.10), rgba(0, 0, 0, 0) 60%),
    linear-gradient(rgba(0, 0, 0, 0.50), rgba(0, 0, 0, 0.50)),
    url('/data/background.webp');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  color: var(--text-color);
  font-size: 1.2rem;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden; 
  position: relative;
  scroll-behavior: smooth;
  padding-top: 70px; /* Abstand für die fixierte Leiste */
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  flex: 1;
  margin-top: 30px;
}

/* ==========================================================================
   03. KARTEN (CARDS) & SLOGANS
   ========================================================================== */
.card-style {
  background: linear-gradient(135deg, rgba(224, 234, 240, 0.92) 0%, rgba(251, 246, 232, 0.92) 100%);
  border: 1px solid var(--stroke);
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
  padding: 25px;
  margin-bottom: 30px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.3s ease;
  overflow: hidden;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px); 
}

@media (hover: hover) {
  .card-style:hover {
    border-color: var(--stroke-strong);
    box-shadow: var(--shadow-md);
  }
}

.page-card {
  padding: 30px;
  margin-bottom: 0;
  position: relative;
  overflow: visible;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(250, 252, 255, 0.85));
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-md);
}

.slogan-card {
  padding: 15px 40px;
  margin-bottom: 30px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-left: 5px solid var(--primary-gold);
  background: linear-gradient(135deg, rgba(224, 234, 240, 0.95) 0%, rgba(251, 246, 232, 0.95) 100%);
  border: 1px solid var(--stroke);
  box-shadow: 0 10px 26px rgba(10, 40, 60, 0.08);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.slogan-text { font-size: 1.5rem; text-align: center; margin: 0; }
.slogan-text .blue { color: var(--primary-blue); font-weight: bold; }
.slogan-text .gold { color: var(--primary-gold); font-weight: bold; }

/* ==========================================================================
   04. HEADER & LOGO
   ========================================================================== */
.header-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100px;
  padding: 0 40px;
  border-bottom: 3px solid var(--primary-gold);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(255, 255, 255, 0.70));
  border: 1px solid var(--stroke);
  box-shadow: 0 12px 28px rgba(10, 40, 60, 0.10);
  position: relative;
  z-index: 10;
  overflow: visible;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.logo-wrapper {
  position: relative;
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.brand-logo {
  height: 420px;
  width: auto;
  display: block;
  cursor: pointer;
  transition: transform 0.3s ease;
  margin-top: -10px;
  margin-left: -50px;
  margin-bottom: 0;
  object-fit: contain;
  filter: drop-shadow(5px 10px 10px rgba(0, 0, 0, 0.15));
  position: relative;
  z-index: 20;
}
@media (hover: hover) {
  .brand-logo:hover { transform: scale(1.02); }
}

.nav-buttons {
  display: flex;
  gap: 15px;
  margin-left: auto;
  z-index: 50;
}

.nav-btn {
  font-family: 'Acme', cursive;
  font-size: 1.05rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(245, 248, 250, 0.70));
  border: 1px solid rgba(0, 51, 78, 0.35);
  color: rgba(0, 51, 78, 0.95);
  padding: 8px 18px;
  border-radius: 255px 15px 225px 15px / 15px 225px 15px 255px;
  cursor: pointer;
  user-select: none; 
  -webkit-user-select: none;
  transition: all 0.25s ease;
  white-space: nowrap;
  box-shadow: 0 8px 16px rgba(10, 40, 60, 0.10);
  filter: saturate(0.88);
}
@media (hover: hover) {
  .nav-btn:hover {
    background: rgba(212, 175, 55, 0.28);
    border-color: rgba(212, 175, 55, 0.65);
    color: rgba(0, 51, 78, 0.98);
    transform: translateY(-1px);
  }
}

/* ==========================================================================
   05. VIEW SWITCHER
   ========================================================================== */
.view-switcher-container {
  display: flex;
  justify-content: center;
  margin-bottom: 25px;
  margin-top: 10px;
  position: relative;
  z-index: 40;
}

.view-switcher {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(245, 248, 250, 0.8));
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 6px;
  display: inline-flex;
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(6px);
}

.switcher-btn {
  background: transparent;
  border: none;
  padding: 10px 30px;
  font-family: 'Acme', cursive;
  font-size: 1.2rem;
  cursor: pointer;
  border-radius: 999px;
  color: var(--primary-blue);
  transition: all 0.3s ease;
  user-select: none;
  outline: none;
}

.switcher-btn:hover {
  background: rgba(0, 51, 78, 0.05);
}

.switcher-btn.active {
  background: var(--primary-gold);
  color: white;
  box-shadow: 0 4px 12px rgba(212, 175, 55, 0.4);
  text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

/* ==========================================================================
   06. SUCHE & FILTER
   ========================================================================== */
.mobile-filter-toggle {
  display: none; 
  width: 100%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(240, 246, 250, 0.85));
  border: 2px solid var(--primary-gold); 
  color: var(--primary-blue);
  padding: 12px 20px;
  font-family: 'Acme', cursive;
  font-size: 1.25rem;
  font-weight: bold;
  border-radius: 15px;
  cursor: pointer;
  margin-top: 20px;
  margin-bottom: 10px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(10, 40, 60, 0.08);
  transition: all 0.2s ease;
}
.mobile-filter-toggle.active {
  background: rgba(212, 175, 55, 0.15);
  border-color: var(--primary-blue);
}

.search-filter-container {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 30px;
  margin-top: 20px;
  position: relative;
  z-index: 30;
}
.search-filter-container .card-style { min-width: 0; }

.search-input {
  width: 100%;
  padding: 10px 15px;
  font-family: 'Acme', cursive;
  font-size: 1.1rem;
  border: 1px solid rgba(0, 0, 0, 0.14);
  border-radius: 255px 15px 225px 15px / 15px 225px 15px 255px;
  outline: none;
  color: var(--primary-blue);
  transition: border-color 0.25s, box-shadow 0.25s;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(245, 248, 250, 0.72));
}
.search-input:focus {
  border-color: rgba(212, 175, 55, 0.9);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.18);
}

/* ==========================================================================
   07. GENRES
   ========================================================================== */
.genre-top-row {
  display: flex;
  gap: 10px;
  margin-bottom: 15px;
  align-items: center;
}
.selected-genres-area { display: flex; gap: 6px; flex-wrap: wrap; }

.selected-tag {
  background: rgba(0, 51, 78, 0.88);
  color: rgba(255, 255, 255, 0.95);
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.95rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  box-shadow: 0 8px 16px rgba(10, 40, 60, 0.12);
  transition: 0.2s ease;
  user-select: none;
}
@media (hover: hover) {
  .selected-tag:hover { background: rgba(192, 57, 43, 0.9); }
}
.selected-tag .tag-x { font-size: 1.1rem; line-height: 1; }

.genre-scroll-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  position: relative;
}
.genre-scroll-row::before,
.genre-scroll-row::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 26px;
  pointer-events: none;
  z-index: 2;
}
.genre-scroll-row::before {
  left: 0;
  background: linear-gradient(90deg, rgba(250, 252, 255, 0.98), rgba(250, 252, 255, 0));
  border-radius: 999px;
}
.genre-scroll-row::after {
  right: 46px;
  background: linear-gradient(270deg, rgba(250, 252, 255, 0.98), rgba(250, 252, 255, 0));
  border-radius: 999px;
}

.genre-scroll-list {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  white-space: nowrap;
  padding: 10px 12px;
  flex: 1;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(245, 248, 250, 0.68));
  border: 1px solid rgba(0, 0, 0, 0.10);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6);
  scrollbar-width: thin;
  scrollbar-color: rgba(212, 175, 55, 0.8) transparent;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
  position: relative;
  z-index: 1;
}
.genre-scroll-list::-webkit-scrollbar { height: 8px; }
.genre-scroll-list::-webkit-scrollbar-thumb {
  background-color: rgba(212, 175, 55, 0.75);
  border-radius: 999px;
  border: 2px solid rgba(255, 255, 255, 0.7);
}
.genre-scroll-list::-webkit-scrollbar-track { background: transparent; }

.genre-pill {
  padding: 7px 14px;
  border: 1px solid rgba(0, 51, 78, 0.28);
  border-radius: 999px;
  cursor: pointer;
  font-size: 1rem;
  flex-shrink: 0;
  transition: all 0.2s ease;
  user-select: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(245, 248, 250, 0.72));
  color: rgba(0, 51, 78, 0.95);
  scroll-snap-align: start;
  box-shadow: 0 8px 16px rgba(10, 40, 60, 0.08);
}
@media (hover: hover) {
  .genre-pill:hover {
    transform: translateY(-1px);
    background: rgba(0, 51, 78, 0.08);
    border-color: rgba(0, 51, 78, 0.40);
  }
}
.genre-pill.active {
  background: rgba(212, 175, 55, 0.26);
  border-color: rgba(212, 175, 55, 0.70);
}
.genre-pill.not-available {
  opacity: 0.45;
  border-style: dashed;
}
@media (hover: hover) {
  .genre-pill.not-available:hover { opacity: 0.7; }
}

.show-all-btn {
  background: rgba(212, 175, 55, 0.82);
  color: rgba(255, 255, 255, 0.95);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  box-shadow: 0 10px 20px rgba(10, 40, 60, 0.12);
  transition: 0.2s ease;
  z-index: 3;
}
@media (hover: hover) {
  .show-all-btn:hover { transform: translateY(-1px); filter: saturate(0.95); }
}

/* ==========================================================================
   08. TAGESAUTOREN BANNER
   ========================================================================== */
.daily-authors-banner {
  width: 100%;
  position: relative;
  height: 88px;
  margin: 6px 0 6px 0;
  display: flex;
  justify-content: center;
  overflow: visible;
  z-index: 6;
}
.daily-authors-banner img {
  position: absolute;
  left: 50%;
  top: -142px;
  transform: translateX(-50%);
  height: 460px;
  width: min(1120px, 96%);
  object-fit: contain;
  object-position: center;
  filter: drop-shadow(0 16px 28px rgba(10, 40, 60, 0.14));
  opacity: 0.98;
}

/* ==========================================================================
   09. GRID (Startseite)
   ========================================================================== */
.authors-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin-top: var(--authors-grid-top);
  position: relative;
  z-index: 25;
}

.author-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--stroke);
  cursor: pointer;
  height: 100%;
  border-radius: 8px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(224, 234, 240, 0.92) 0%, rgba(251, 246, 232, 0.92) 100%);
  box-shadow: 0 10px 26px rgba(10, 40, 60, 0.10);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.3s ease;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  user-select: none;
  -webkit-user-select: none;
  touch-action: manipulation;
}

@media (hover: hover) {
  .author-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 18px 40px rgba(10, 40, 60, 0.14);
    border-color: var(--stroke-strong);
    background: linear-gradient(135deg, rgba(214, 226, 235, 0.98) 0%, rgba(247, 238, 215, 0.98) 100%);
  }
}

.author-img-placeholder,
.author-profile-img {
  width: 100%;
  height: 350px;
  background: linear-gradient(180deg, rgba(230, 242, 248, 0.95), rgba(240, 246, 250, 0.85));
  border-radius: 12px;
  margin-bottom: 15px;
  display: block;
  color: var(--primary-blue);
  font-size: 1.5rem;
  opacity: 0.98;
  object-fit: cover;
  border: 1px solid rgba(0, 51, 78, 0.08);
}
.author-img-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
}

.author-name {
  margin: 0 0 10px 0;
  font-size: 1.6rem;
  border-bottom: 2px solid var(--primary-gold);
  display: inline-block;
  width: fit-content;
  color: var(--primary-blue);
}
.author-bio {
  font-size: 1.1rem;
  line-height: 1.4;
  color: #4b5963;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

/* -------------------- GRID FÜR DIE ALLE-AUTOREN-SEITE (trueall.php) -------------------- */
.authors-grid-all {
  display: grid;
  grid-template-columns: repeat(5, 1fr); 
  gap: 25px;
  margin-top: var(--authors-grid-top);
  position: relative;
  z-index: 25;
}

.authors-grid-all .author-img-placeholder,
.authors-grid-all .author-profile-img {
  height: auto;
  aspect-ratio: 1 / 1; 
  margin-bottom: 10px;
}

@media (max-width: 1200px) { .authors-grid-all { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 900px) { .authors-grid-all { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 600px) {
  .authors-grid-all { 
    grid-template-columns: repeat(2, 1fr); 
    gap: 12px; 
  }
  .authors-grid-all .author-name {
    font-size: 1.15rem; 
    margin-bottom: 5px;
  }
  .authors-grid-all .author-bio {
    font-size: 0.95rem; 
    -webkit-line-clamp: 2; 
  }
}

/* ==========================================================================
   10. FOOTER
   ========================================================================== */
footer {
  margin-top: 50px;
  text-align: center;
  padding: 28px 0 40px 0;
  color: var(--text-color);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(245, 248, 250, 0.70));
  border-top: 1px solid rgba(0, 51, 78, 0.12);
  border-radius: 16px;
  box-shadow: 0 10px 26px rgba(10, 40, 60, 0.10);
  margin-bottom: 0;
}

.footer-links {
  margin-top: 15px;
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.footer-btn {
  font-family: 'Acme', cursive;
  font-size: 1.05rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(245, 248, 250, 0.70));
  border: 1px solid rgba(0, 51, 78, 0.35);
  color: rgba(0, 51, 78, 0.95);
  padding: 8px 18px;
  border-radius: 255px 15px 225px 15px / 15px 225px 15px 255px;
  cursor: pointer;
  transition: all 0.25s ease;
  white-space: nowrap;
  box-shadow: 0 8px 16px rgba(10, 40, 60, 0.10);
  filter: saturate(0.88);
  text-decoration: none;
  user-select: none;
  -webkit-user-select: none;
}
@media (hover: hover) {
  .footer-btn:hover {
    background: rgba(212, 175, 55, 0.28);
    border-color: rgba(212, 175, 55, 0.65);
    color: rgba(0, 51, 78, 0.98);
    transform: translateY(-1px);
  }
}

/* ==========================================================================
   11. MODALS
   ========================================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 40, 60, 0.62);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: none; 
  justify-content: center;
  align-items: center; 
  z-index: 9999 !important;
  padding: 20px; 
  -webkit-overflow-scrolling: touch;
  padding-bottom: calc(90px + env(safe-area-inset-bottom)) !important;
}

.info-card {
  border: 1px solid rgba(212, 175, 55, 0.55);
  position: relative;
  width: min(900px, 100%); 
  max-height: calc(100vh - 130px - env(safe-area-inset-bottom)) !important;
  overflow-y: auto; 
  margin: auto; 
  background: linear-gradient(135deg, rgba(235, 244, 250, 0.98) 0%, rgba(253, 245, 225, 0.96) 100%);
  padding: 30px;
  border-radius: 8px;
  animation: popUp 0.3s ease-out;
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.25);
}

.info-card.wide-modal { max-width: 900px; }
@media (min-width: 901px) {
  .info-card.wide-modal { max-width: 1100px; }
}

@keyframes popUp {
  from { transform: scale(0.95); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.close-modal {
  position: sticky;
  top: 0;
  float: right; 
  margin-top: -10px; 
  margin-right: -10px;
  font-size: 2rem;
  cursor: pointer;
  background: none;
  border: none;
  font-family: 'Acme', cursive;
  color: var(--primary-blue);
  z-index: 100;
  padding: 5px 15px; 
}

.logo-modal-content { text-align: center; }
.logo-large { max-width: 100%; height: auto; margin-bottom: -80px; }

.author-profile-container {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 30px;
  margin-top: 20px;
  position: relative;
}

.social-icons-container {
  position: absolute;
  bottom: 20px;
  right: 20px;
  display: flex;
  gap: 10px;
}
.social-icon {
  width: 38px;
  height: 38px;
  background: rgba(0, 51, 78, 0.90);
  color: white;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: 0.25s ease;
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.14);
}
.social-icon svg { width: 20px; height: 20px; fill: rgba(255, 255, 255, 0.95); }
@media (hover: hover) {
  .social-icon:hover {
    background: rgba(212, 175, 55, 0.88);
    transform: translateY(-1px);
  }
}

.book-preview-list { display: flex; gap: 14px; flex-wrap: wrap; }
.book-item { width: 120px; cursor: pointer; text-align: center; }
.book-cover-small {
  width: 120px;
  height: 170px;
  border-radius: 10px;
  border: 1px solid rgba(0, 0, 0, 0.10);
  background: rgba(240, 240, 240, 0.95);
  background-position: center;
  background-size: cover;
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.10);
  margin-bottom: 6px;
}

.book-detail-container {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 20px;
  align-items: start;
}
.book-detail-cover {
  width: 260px;
  height: 360px;
  border-radius: 12px;
  border: 1px solid rgba(0, 0, 0, 0.10);
  background: rgba(240, 240, 240, 0.95);
  background-position: center;
  background-size: cover;
  box-shadow: 0 12px 22px rgba(0, 0, 0, 0.12);
}

/* ==========================================================================
   12. DASHBOARD & FORMS (Gefiltert für Auth & Modals)
   ========================================================================== */
.form-group { margin-bottom: 15px; position: relative; }
.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
  color: var(--primary-blue);
}

.form-input,
.form-textarea {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box; 
  padding: 10px;
  font-family: 'Acme', cursive;
  font-size: 1.1rem;
  border: 1px solid rgba(0, 0, 0, 0.14);
  border-radius: 255px 15px 225px 15px / 15px 225px 15px 255px;
  outline: none;
  transition: all 0.25s ease;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(245, 248, 250, 0.78));
}
.form-input:focus,
.form-textarea:focus {
  border-color: rgba(0, 51, 78, 0.55);
  box-shadow: 0 0 0 3px rgba(0, 51, 78, 0.12);
}
.form-textarea { height: 120px; resize: vertical; }

.submit-btn,
.action-btn {
  background-color: rgba(0, 51, 78, 0.90);
  color: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(0, 0, 0, 0.08);
  padding: 9px 16px;
  font-family: 'Acme', cursive;
  font-size: 1.15rem;
  border-radius: 255px 15px 225px 15px / 15px 225px 15px 255px;
  cursor: pointer;
  margin-top: 10px;
  transition: all 0.25s ease;
  width: 100%;
  box-shadow: 0 10px 22px rgba(10, 40, 60, 0.12);
  filter: saturate(0.88);
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
@media (hover: hover) {
  .submit-btn:hover,
  .action-btn:hover {
    background-color: rgba(212, 175, 55, 0.82);
    transform: translateY(-1px);
  }
}
.secondary-btn {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.74), rgba(245, 248, 250, 0.68));
  border: 1px solid rgba(0, 51, 78, 0.30);
  color: rgba(0, 51, 78, 0.95);
}
@media (hover: hover) {
  .secondary-btn:hover { background: rgba(0, 51, 78, 0.10); }
}

.btn-small { width: auto; font-size: 1rem; padding: 5px 15px; display: inline-block; }
.btn-outline {
  background: transparent;
  border: 1px solid rgba(0, 51, 78, 0.55);
  color: rgba(0, 51, 78, 0.95);
}
@media (hover: hover) {
  .btn-outline:hover { background: rgba(0, 51, 78, 0.10); color: rgba(0, 51, 78, 1); }
}

.genre-suggestions {
  position: absolute;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(245, 248, 250, 0.88));
  border: 1px solid rgba(0, 0, 0, 0.14);
  width: 100%;
  max-height: 150px;
  overflow-y: auto;
  z-index: 100;
  border-radius: 12px;
  display: none;
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.12);
}
.suggestion-item {
  padding: 8px 10px;
  cursor: pointer;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
@media (hover: hover) {
  .suggestion-item:hover {
    background-color: rgba(230, 240, 245, 0.85);
    color: var(--primary-blue);
  }
}

.selected-genre-tag {
  display: inline-flex;
  align-items: center;
  background: rgba(0, 51, 78, 0.90);
  color: rgba(255, 255, 255, 0.95);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.95rem;
  margin-right: 5px;
  margin-bottom: 5px;
  box-shadow: 0 8px 16px rgba(10, 40, 60, 0.12);
}
.selected-genre-tag span {
  cursor: pointer;
  margin-left: 8px;
  font-weight: bold;
}

.switch-link {
  margin-top: 15px;
  text-align: center;
  font-size: 1rem;
  color: #5b6670;
}
.switch-link span {
  color: var(--primary-blue);
  text-decoration: underline;
  cursor: pointer;
  font-weight: bold;
}

.checkbox-group {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  font-size: 1rem;
}
.checkbox-group input {
  width: 20px;
  height: 20px;
  accent-color: rgba(0, 51, 78, 0.85);
}

.author-link {
  display: block;
  background-color: rgba(0, 51, 78, 0.90);
  color: rgba(255, 255, 255, 0.95);
  text-decoration: none;
  padding: 8px 12px;
  border-radius: 10px;
  text-align: center;
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-shadow: 0 10px 18px rgba(10, 40, 60, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.10);
}
@media (hover: hover) {
  .author-link:hover { background-color: rgba(212, 175, 55, 0.82); }
}

/* ==========================================================================
   13. A-Z & SOCIALS
   ========================================================================== */
.az-tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.20);
  padding-bottom: 10px;
}
.az-tab {
  cursor: pointer;
  padding: 6px 10px;
  border-radius: 10px;
  font-weight: bold;
  color: rgba(0, 51, 78, 0.95);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(245, 248, 250, 0.68));
  border: 1px solid rgba(0, 0, 0, 0.10);
  transition: 0.2s ease;
  box-shadow: 0 8px 14px rgba(10, 40, 60, 0.08);
  user-select: none;
}
.az-tab.active {
  background-color: rgba(212, 175, 55, 0.30);
  color: rgba(0, 51, 78, 1);
  border-color: rgba(212, 175, 55, 0.50);
}
@media (hover: hover) {
  .az-tab:hover {
    background-color: rgba(212, 175, 55, 0.30);
    color: rgba(0, 51, 78, 1);
    border-color: rgba(212, 175, 55, 0.50);
  }
}

.mini-author-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid rgba(0, 0, 0, 0.10);
  border-radius: 12px;
  cursor: pointer;
  transition: 0.2s;
  background: linear-gradient(135deg, rgba(224, 234, 240, 0.92) 0%, rgba(251, 246, 232, 0.92) 100%);
  text-align: left;
  box-shadow: 0 10px 18px rgba(10, 40, 60, 0.08);
  backdrop-filter: blur(6px);
  user-select: none;
}
@media (hover: hover) {
  .mini-author-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 28px rgba(0, 0, 0, 0.10);
    background: linear-gradient(135deg, rgba(214, 226, 235, 0.98) 0%, rgba(247, 238, 215, 0.98) 100%);
  }
}

.mini-author-img {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
  background: linear-gradient(180deg, rgba(230, 242, 248, 0.95), rgba(245, 250, 255, 0.85));
  border: 1px solid rgba(0, 51, 78, 0.10);
}
.mini-author-name {
  font-weight: bold;
  color: rgba(0, 51, 78, 0.95);
  margin: 0;
}

.all-genres-grid,
.all-authors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px;
  margin-top: 15px;
}

/* ==========================================================================
   14. RESPONSIVE
   ========================================================================== */
@media (max-width: 900px) {
  :root { --authors-grid-top: 66px; }

  .mobile-filter-toggle {
    display: block;
    position: relative;
    z-index: 40;
  }
  
  .search-filter-container { 
    display: none; 
    grid-template-columns: 1fr; 
    gap: 10px; 
    margin-top: 5px; 
  }

  .search-filter-container .card-style {
    margin-bottom: 0 !important;
  }

  .search-filter-container.open {
    display: grid;
  }

  .authors-grid { grid-template-columns: repeat(2, 1fr); }
  .genre-scroll-row::after { right: 46px; }

  .daily-authors-banner { height: 78px; margin: 22px 0 6px 0; }
  .daily-authors-banner img {
    height: 210px;
    top: -62px;
    width: min(980px, 96%);
    transform: translateX(-50%);
  }
}

@media (max-width: 600px) {
  body { padding: 12px; }

  .header-card {
    flex-direction: column;
    height: auto;
    padding: 10px;
    gap: 10px;
    text-align: center;
  }
  .logo-wrapper { align-items: center; margin-bottom: 20px; max-width: 100%; }
  .brand-logo {
    margin: 0 auto;
    height: 230px;
    margin-top: -120px;
    margin-bottom: -90px;
    margin-left: -70px;
    width: auto;
    max-width: 150%;
  }

  .nav-buttons {
    margin: 0;
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
    z-index: 50;
    gap: 10px;
  }
  .nav-btn {
    padding: 7px 14px;
    width: auto;
    flex: 1 1 auto;
    font-size: 1rem;
  }

  :root { --authors-grid-top: 42px; }
  .authors-grid { grid-template-columns: 1fr; gap: 20px; }

  .author-profile-container { grid-template-columns: 1fr; padding-bottom: 55px; }
  .author-profile-img,
  .author-img-placeholder {
    width: 100%;
    max-width: 200px;
    height: 280px;
    margin: 0 auto 15px auto;
  }

  .info-card {
    padding: 15px 20px;
    width: min(900px, 100%);
    max-height: 85vh;
  }

  .genre-top-row { flex-direction: column; align-items: stretch; }
  .genre-scroll-list { padding: 10px 10px; gap: 10px; }
  .genre-pill { padding: 9px 14px; font-size: 1.02rem; }
  .genre-scroll-row::before { width: 18px; }
  .genre-scroll-row::after { width: 18px; right: 46px; }

  .social-icons-container {
    position: relative;
    bottom: auto;
    right: auto;
    justify-content: center;
    margin-top: 18px;
  }

  .book-detail-container { grid-template-columns: 1fr; }
  .book-detail-cover {
    width: 100%;
    max-width: 260px;
    height: 360px;
    margin: 0 auto;
  }

  .daily-authors-banner {
    height: 102px;
    margin: 16px 0 6px 0;
  }
  .daily-authors-banner img {
    height: 220px;
    top: -28px;
    width: min(720px, 92%);
    transform: translateX(-50%);
  }

  footer {
    margin-top: 26px;
    padding: 22px 12px 30px 12px;
    border-radius: 14px;
  }
  .footer-links { gap: 10px; }
  .footer-btn {
    flex: 1 1 auto;
    min-width: 140px;
    text-align: center;
  }
}

@media (max-height: 450px) and (orientation: landscape) {
  .header-card {
    height: 70px;
    padding: 0 20px;
    align-items: center;
    overflow: visible;
  }
  .logo-wrapper { position: relative; z-index: 30; max-height: none; }
  .brand-logo {
    height: 250px;
    margin-top: -60px;
    margin-left: -40px;
    margin-bottom: -60px;
  }
  .nav-buttons { z-index: 10; gap: 10px; }
  .nav-btn { padding: 6px 14px; font-size: 1rem; white-space: nowrap; }
}

.btn-inline {
  width: auto !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 7px 14px;
}

.button-row { display: flex; flex-wrap: wrap; gap: 10px; }

.action-btn.danger { background: #c0392b !important; }
@media (hover: hover) {
  .action-btn.danger:hover { filter: brightness(0.95); }
}

.book-detail-covers-row {
  display: flex;
  gap: 15px;
  justify-content: center;
  width: 100%;
}
.book-detail-cover {
  width: 220px;
  height: 330px;
  flex-shrink: 0;
  border-radius: 12px;
  border: 1px solid rgba(0, 0, 0, 0.10);
  background-color: rgba(240, 240, 240, 0.95);
  background-position: center;
  background-size: cover;
  box-shadow: 0 12px 22px rgba(0, 0, 0, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #888;
}

@media (max-width: 600px) {
  .book-detail-covers-row {
    flex-direction: column;
    align-items: center;
  }
  .book-detail-cover {
    width: 100%;
    max-width: 240px;
    height: 360px;
    margin-bottom: 15px;
  }
}

/* ==========================================================================
   15. TOAST NOTIFICATIONS
   ========================================================================== */
.toast-msg {
  position: fixed;
  top: 30px;
  left: 50%;
  transform: translateX(-50%) translateY(-30px); 
  background: linear-gradient(135deg, rgba(250, 252, 255, 0.95) 0%, rgba(253, 250, 245, 0.95) 100%);
  border-radius: 255px 15px 225px 15px / 15px 225px 15px 255px; 
  padding: 12px 24px;
  font-family: 'Acme', cursive;
  font-size: 1.15rem;
  z-index: 9999;
  box-shadow: 0 12px 30px rgba(10, 40, 60, 0.15);
  border: 1px solid var(--stroke);
  opacity: 0; 
  transition: all 0.5s cubic-bezier(0.25, 1, 0.5, 1); 
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  pointer-events: none; 
}
.toast-msg.show {
  transform: translateX(-50%) translateY(0); 
  opacity: 1; 
}
.toast-msg.error-toast { color: #c0392b; border-left: 4px solid #c0392b; }
.toast-msg.success-toast { color: #27ae60; border-left: 4px solid #27ae60; }

/* ==========================================================================
   16. BLOGGER SPEZIFISCH
   ========================================================================== */
.rating-grid {
  display: grid; 
  grid-template-columns: 1fr 1fr; 
  gap: 15px; 
  background: white; 
  padding: 15px; 
  border-radius: 10px; 
  border: 1px solid #ddd;
}
@media (max-width:600px){
  .rating-grid { grid-template-columns: 1fr; gap: 10px; padding: 10px; }
}

.rating-item { display: flex; justify-content: space-between; align-items: center; font-size: 1rem; }
.rating-select { 
  padding: 8px; 
  border-radius: 8px; 
  border: 1px solid rgba(0, 0, 0, 0.14); 
  font-family: inherit; 
  font-size: 1rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(245, 248, 250, 0.78));
  color: var(--primary-blue);
  outline: none;
}

.tag-accordion {
  background: white;
  border: 1px solid #ddd;
  border-radius: 10px;
  margin-bottom: 10px;
  overflow: hidden;
}
.tag-accordion summary {
  padding: 12px 15px;
  font-weight: bold;
  color: var(--primary-blue);
  background: rgba(0,51,78,0.03);
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.tag-accordion summary::-webkit-details-marker { display: none; }
.tag-accordion summary::after { content: '▾'; color: var(--primary-gold); font-size: 1.2rem; }
.tag-accordion[open] summary::after { content: '▴'; }
.tag-content { padding: 15px; display: flex; flex-wrap: wrap; gap: 8px; border-top: 1px solid #eee; }

.tag-checkbox-label { 
  display: inline-block; 
  background: rgba(0,51,78,0.05); 
  border: 1px solid rgba(0,51,78,0.2); 
  padding: 6px 12px; 
  border-radius: 20px; 
  cursor: pointer; 
  transition: 0.2s; 
  user-select: none; 
  font-size: 0.95rem;
}
.tag-checkbox-label:hover { background: rgba(0,51,78,0.1); }
.tag-checkbox-label.checked { background: var(--primary-blue); color: white; border-color: var(--primary-blue); }
.tag-checkbox-label input { display: none; }

/* --- FIX FÜR DIE BILDER IM VORSCHAU-MODAL (4 BILDER) --- */
@media (max-width: 600px) {
  .book-detail-covers-row {
    justify-content: flex-start;
  }
}

@media (min-width: 601px) {
  .book-detail-covers-row {
    justify-content: center;
  }
  
  .book-detail-cover {
    width: 150px !important; 
    height: 225px !important;
    flex-shrink: 0;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
  }
}

/* ==========================================================================
   18. FOOTER MOBILE TOGGLE
   ========================================================================== */
.footer-header {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
}

.footer-chevron {
  display: none; 
  color: var(--primary-gold);
  font-size: 1.2rem;
  transition: transform 0.3s ease;
}

.footer-chevron.rotated {
  transform: rotate(180deg);
}

@media (max-width: 900px) {
  .footer-header {
    cursor: pointer;
    padding: 5px 0;
  }
  .footer-chevron {
    display: inline-block;
  }
  .footer-links {
    display: none; 
    flex-direction: column;
    gap: 8px;
    margin-top: 15px;
  }
  .footer-links.show {
    display: flex;
  }
}

/* ==========================================================================
   20. TICKER CONTAINER
   ========================================================================== */
.news-ticker-container {
  background-color: var(--primary-blue);
  color: #fff;
  padding: 8px 0;
  overflow: hidden;
  position: relative;
  white-space: nowrap;
  display: flex;
  align-items: center;
  border-bottom: 2px solid var(--primary-gold);
  margin-bottom: 20px;
  border-radius: 8px;
  z-index: 50 !important;
}

.news-badge {
  background-color: var(--primary-gold);
  color: var(--primary-blue);
  font-weight: bold;
  padding: 2px 10px;
  border-radius: 4px;
  margin-left: 10px;
  margin-right: 15px;
  z-index: 2;
  position: relative;
  box-shadow: 2px 0 5px rgba(0,51,78,0.5);
}

.ticker-text {
  display: inline-block;
  padding-left: 100%;
  animation: ticker 220s linear infinite;
  font-size: 1.05rem;
  letter-spacing: 0.5px;
}

.news-ticker-container:hover .ticker-text {
  animation-play-state: paused;
}

.ticker-link-btn {
  background-color: var(--primary-gold);
  color: var(--primary-blue);
  padding: 2px 10px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: bold;
  font-size: 0.9rem;
  margin: 0 8px;
  transition: filter 0.2s;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}
.ticker-link-btn:hover {
  filter: brightness(1.1);
}

@keyframes ticker {
  0% { transform: translateX(0); }
  100% { transform: translateX(-100%); }
}

/* ==========================================================================
   21. PARTNER LOGO
   ========================================================================== */
.partner-logo {
  width: 100%;
  height: auto;
  object-fit: contain;
  mix-blend-mode: multiply;
  transform: scale(1.4) translateX(15px);
}

@media (max-width: 900px) {
  .partner-logo {
    transform: scale(1.2) translateX(0px); 
  }
}

/* ==========================================================================
   22. DUNKELMODUS (DARK MODE) OVERRIDES
   ========================================================================== */
body.dark-mode {
  --primary-blue: #005a8a;
  --bg-color: #12181b; 
  --text-color: #e0e6ed;
  --stroke: rgba(255, 255, 255, 0.12);
  --stroke-strong: rgba(255, 255, 255, 0.25);
  
  background-color: var(--bg-color);
  background-image:
    radial-gradient(1200px 600px at 10% 0%, rgba(212, 175, 55, 0.05), rgba(0, 0, 0, 0) 60%),
    radial-gradient(900px 500px at 90% 20%, rgba(138, 180, 248, 0.05), rgba(0, 0, 0, 0) 60%),
    linear-gradient(rgba(18, 24, 27, 0.85), rgba(18, 24, 27, 0.95)),
    url('/data/background.webp');
}

body.dark-mode .card-style,
body.dark-mode .page-card,
body.dark-mode .header-card,
body.dark-mode .info-card,
body.dark-mode footer {
  background: linear-gradient(135deg, rgba(30, 40, 50, 0.85) 0%, rgba(20, 25, 30, 0.90) 100%);
  border-color: var(--stroke);
  color: var(--text-color);
}

body.dark-mode .author-name,
body.dark-mode .slogan-text .blue,
body.dark-mode h2,
body.dark-mode h3,
body.dark-mode .form-group label {
  color: var(--primary-gold); 
}

body.dark-mode .author-bio,
body.dark-mode p {
  color: #b0c4de;
}

body.dark-mode .nav-btn,
body.dark-mode .footer-btn,
body.dark-mode .switcher-btn,
body.dark-mode .search-input,
body.dark-mode .form-input,
body.dark-mode .form-textarea,
body.dark-mode .genre-pill {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-color);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

body.dark-mode .nav-btn:hover,
body.dark-mode .footer-btn:hover,
body.dark-mode .genre-pill:hover {
  background: rgba(212, 175, 55, 0.2);
  border-color: var(--primary-gold);
  color: var(--primary-gold);
}

body.dark-mode .modal-overlay { background: rgba(0, 0, 0, 0.8); }
body.dark-mode .close-modal { color: var(--primary-gold); }

body.dark-mode .mini-author-card {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.1);
  color: var(--text-color);
}

body.dark-mode .view-switcher {
  background: rgba(0, 0, 0, 0.3);
  border-color: rgba(255, 255, 255, 0.1);
}
body.dark-mode .switcher-btn { color: #b0c4de; }
body.dark-mode .switcher-btn.active {
  background: var(--primary-gold);
  color: #12181b;
}

body.dark-mode .search-input::placeholder,
body.dark-mode .form-input::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

body.dark-mode .secondary-btn {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #e0e6ed !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}

body.dark-mode .genre-scroll-list {
  background: rgba(0, 0, 0, 0.2);
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: none;
}
body.dark-mode .genre-scroll-row::before { background: linear-gradient(90deg, var(--bg-color), transparent) !important; }
body.dark-mode .genre-scroll-row::after { background: linear-gradient(270deg, var(--bg-color), transparent) !important; }

body.dark-mode #challengeGenreContainer {
  background: rgba(0, 0, 0, 0.2) !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}
body.dark-mode #challengeGenreContainer .genre-pill {
  background: rgba(255, 255, 255, 0.1);
  color: #e0e6ed;
  border-color: rgba(255, 255, 255, 0.2);
}
body.dark-mode #challengeStep1 p,
body.dark-mode #challengeStep2 p { color: #b0c4de !important; }

body.dark-mode #modalContent p,
body.dark-mode #modalContent div,
body.dark-mode #modalContent span { color: #b0c4de !important; }

body.dark-mode #modalContent .selected-tag,
body.dark-mode #modalContent .badge-status { color: #fff !important; }

body.dark-mode #modalContent .action-btn,
body.dark-mode #modalContent .action-btn span {
  background: var(--primary-gold) !important;
  color: #12181b !important;
  border: none !important;
}

body.dark-mode #modalContent div[style*="border: 1px solid"] {
  background: rgba(0, 0, 0, 0.2) !important;
  border-color: rgba(212, 175, 55, 0.4) !important;
}
body.dark-mode #modalContent div[style*="border: 1px solid"] b,
body.dark-mode #modalContent div[style*="border: 1px solid"] strong {
  color: #e0e6ed !important;
}

body.dark-mode .form-input,
body.dark-mode .form-textarea,
body.dark-mode .rating-select,
body.dark-mode select {
  background: rgba(0, 0, 0, 0.3) !important;
  color: #e0e6ed !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}

body.dark-mode .genre-suggestions,
body.dark-mode .custom-dropdown-list {
  background: #1a242f !important;
  border: 1px solid rgba(212, 175, 55, 0.5) !important;
  color: #e0e6ed !important;
}
body.dark-mode .suggestion-item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
  color: #e0e6ed !important;
}
body.dark-mode .suggestion-item:hover {
  background: rgba(212, 175, 55, 0.2) !important;
  color: var(--primary-gold) !important;
}

body.dark-mode span[style*="color:green"],
body.dark-mode span[style*="color:rgba(0,120,0,0.9)"] { color: #4ade80 !important; }
body.dark-mode span[style*="color:#c0392b"] { color: #f87171 !important; }

body.dark-mode div[style*="background:#eee"],
body.dark-mode div[style*="background:#ddd"] {
  background: rgba(0, 0, 0, 0.3) !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
  color: #b0c4de !important;
}

body.dark-mode .rating-grid,
body.dark-mode .tag-accordion {
  background: rgba(0, 0, 0, 0.2) !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}
body.dark-mode .tag-accordion summary {
  background: rgba(255, 255, 255, 0.05) !important;
  color: var(--primary-gold) !important;
}
body.dark-mode .tag-content { border-top-color: rgba(255, 255, 255, 0.1) !important; }
body.dark-mode .tag-checkbox-label {
  background: rgba(255, 255, 255, 0.05) !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
  color: #e0e6ed !important;
}
body.dark-mode .tag-checkbox-label:hover { background: rgba(255, 255, 255, 0.1) !important; }
body.dark-mode .tag-checkbox-label.checked {
  background: var(--primary-gold) !important;
  color: #12181b !important;
  border-color: var(--primary-gold) !important;
}

body.dark-mode .info-card {
  background: linear-gradient(135deg, rgba(25, 35, 45, 0.98) 0%, rgba(18, 24, 27, 0.98) 100%) !important;
  border: 1px solid rgba(212, 175, 55, 0.3) !important;
}

body.dark-mode .sidebar {
  background: var(--bg-color) !important;
  border-right: 2px solid var(--stroke-strong) !important;
  box-shadow: 4px 0 15px rgba(0,0,0,0.5) !important;
}
body.dark-mode .sidebar-header-mobile,
body.dark-mode .sidebar-section-title {
  color: var(--primary-gold) !important;
  border-bottom-color: rgba(212, 175, 55, 0.3) !important;
}
body.dark-mode .sidebar-btn {
  background-color: rgba(255, 255, 255, 0.05) !important;
  color: #e0e6ed !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}
body.dark-mode .sidebar-btn:hover {
  background-color: rgba(212, 175, 55, 0.2) !important;
  color: var(--primary-gold) !important;
  border-color: var(--primary-gold) !important;
}

body.dark-mode .az-tab {
  background: rgba(0, 0, 0, 0.3) !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
  color: #e0e6ed !important; 
}

body.dark-mode .az-tab:hover {
  background: rgba(212, 175, 55, 0.2) !important;
  color: var(--primary-gold) !important;
  border-color: var(--primary-gold) !important;
}

body.dark-mode .az-tab.active {
  background: var(--primary-gold) !important;
  color: #12181b !important; 
  border-color: var(--primary-gold) !important;
}

body.dark-mode #modalContent div[style*="background: #eee"],
body.dark-mode #modalContent div[style*="background:#eee"],
body.dark-mode #modalContent div[style*="background: #f0f0f0"],
body.dark-mode #modalContent div[style*="background:#f0f0f0"],
body.dark-mode #modalContent div[style*="background: #e0e0e0"],
body.dark-mode #modalContent div[style*="background:#e0e0e0"] {
  background: rgba(255, 255, 255, 0.08) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

body.dark-mode #modalContent div[style*="background:"] > span,
body.dark-mode #modalContent div[style*="background:"] > div,
body.dark-mode #modalContent div[style*="background:"] > strong,
body.dark-mode #modalContent div[style*="background:"] > i {
  color: #e0e6ed !important;
}

body.dark-mode .action-btn {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #e0e6ed !important; 
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
}

body.dark-mode .action-btn:hover {
  background: var(--primary-gold) !important;
  color: #12181b !important; 
}

body.dark-mode .bs-btn,
body.dark-mode button[style*="background: var(--primary-gold)"],
body.dark-mode button[style*="background:var(--primary-gold)"] {
  background: var(--primary-gold) !important;
  color: #12181b !important; 
  font-weight: bold !important;
}

body.dark-mode .action-btn span, 
body.dark-mode button[style*="var(--primary-gold)"] span {
  color: #12181b !important;
}

body.dark-mode .action-btn.secondary-btn {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #e0e6ed !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
}

body.dark-mode .az-tabs span {
  background: rgba(255, 255, 255, 0.1) !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  color: #e0e6ed !important;
}

body.dark-mode .genre-pill {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #e0e6ed !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
}
body.dark-mode .genre-pill:hover {
  background: rgba(212, 175, 55, 0.2) !important;
  border-color: var(--primary-gold) !important;
  color: var(--primary-gold) !important;
}
body.dark-mode .genre-pill.active {
  background: var(--primary-gold) !important;
  color: #12181b !important;
  border-color: var(--primary-gold) !important;
}

body.dark-mode #btnRollChallenge:disabled,
body.dark-mode #btnRollChallenge[style*="opacity: 0.5"],
body.dark-mode #btnRollChallenge[style*="opacity:0.5"] {
  background: rgba(255, 255, 255, 0.1) !important;
  color: rgba(255, 255, 255, 0.3) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

body.dark-mode .selected-tag {
  background: rgba(255, 255, 255, 0.15) !important;
  color: #e0e6ed !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
}

body.dark-mode .author-link {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #e0e6ed !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
}
body.dark-mode .author-link:hover {
  background: var(--primary-gold) !important;
  color: #12181b !important;
}
body.dark-mode .social-icon { background: rgba(255, 255, 255, 0.1) !important; }
body.dark-mode .social-icon:hover { background: var(--primary-gold) !important; }
body.dark-mode .social-icon svg { fill: #e0e6ed !important; }
body.dark-mode .social-icon:hover svg { fill: #12181b !important; }

body.dark-mode .search-input,
body.dark-mode #mainSearchInput,
body.dark-mode #genreSearchInput,
body.dark-mode #challengeGenreSearch {
  background: rgba(0, 0, 0, 0.4) !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  color: #e0e6ed !important;
}
body.dark-mode .search-input::placeholder { color: rgba(255, 255, 255, 0.5) !important; }
body.dark-mode .search-input:focus {
  border-color: var(--primary-gold) !important;
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2) !important;
}

body.dark-mode #challengeStep1 > div > div[style*="background:#fafafa"],
body.dark-mode #challengeStep1 > div > div[style*="background: #fafafa"] {
  background: rgba(0, 0, 0, 0.3) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}
body.dark-mode #challengeStep1 .genre-pill {
  background: rgba(255, 255, 255, 0.05) !important;
  color: #e0e6ed !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}
body.dark-mode #challengeStep1 .genre-pill:hover {
  background: rgba(212, 175, 55, 0.2) !important;
  border-color: var(--primary-gold) !important;
  color: var(--primary-gold) !important;
}
body.dark-mode #challengeStep1 .genre-pill.active {
  background: var(--primary-gold) !important;
  color: #12181b !important;
  border-color: var(--primary-gold) !important;
}

body.dark-mode #modalContent h3,
body.dark-mode #modalContent h4 {
  color: var(--primary-gold) !important;
  border-bottom-color: rgba(255, 255, 255, 0.1) !important;
}
body.dark-mode #modalContent div[style*="color:#333"],
body.dark-mode #modalContent div[style*="color: #333"] {
  color: #b0c4de !important;
}
body.dark-mode #modalContent .book-item {
  background: rgba(255, 255, 255, 0.05) !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}
body.dark-mode #modalContent .book-item div[style*="color:var(--primary-blue)"] { color: #e0e6ed !important; }
body.dark-mode #modalContent .book-item div[style*="color:#555"] { color: rgba(255, 255, 255, 0.6) !important; }

body.dark-mode #modalContent div[style*="background: rgba(212, 175, 55, 0.1)"],
body.dark-mode #modalContent div[style*="background:rgba(212, 175, 55, 0.1)"] {
  background: rgba(0, 0, 0, 0.3) !important;
  border-color: rgba(212, 175, 55, 0.3) !important;
  color: #e0e6ed !important;
}
body.dark-mode #modalContent div[style*="background: rgba(212, 175, 55, 0.1)"] strong,
body.dark-mode #modalContent div[style*="background:rgba(212, 175, 55, 0.1)"] strong {
  color: var(--primary-gold) !important; 
}
body.dark-mode #modalContent div[style*="color:#2c3e50"],
body.dark-mode #modalContent div[style*="color: #2c3e50"] {
  color: #b0c4de !important;
}

body.dark-mode .mobile-filter-toggle {
  background: rgba(0, 0, 0, 0.3) !important;
  color: var(--primary-gold) !important; 
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
}
body.dark-mode .mobile-filter-toggle.active {
  background: rgba(212, 175, 55, 0.15) !important;
  border-color: var(--primary-gold) !important;
}

body.dark-mode .footer-header { color: #e0e6ed !important; }
body.dark-mode .footer-chevron { color: var(--primary-gold) !important; }

/* Fix für die Lesbarkeit der Genre-Tags im Dark Mode */
body.dark-mode #modalContent .selected-genre-tag {
    color: #00334e !important; /* Dunkelblau für maximalen Kontrast auf Gelb */
    font-weight: bold !important;
}

/* Falls du die Tags im Autoren-Profil meinst (selected-tag) */
body.dark-mode #modalContent .selected-tag {
    color: #ffffff !important; 
    background: rgba(0, 51, 78, 0.9) !important;
}

/* ==========================================================================
   23. MOBILE ANSICHT OPTIMIERUNGEN (ab 900px abwärts)
   ========================================================================== */

.mobile-bottom-bar,
.mobile-sidebar,
.mobile-sidebar-overlay {
  display: none;
}

@media (max-width: 900px) {
  .mobile-bottom-bar {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(245, 248, 250, 0.98)) !important;
    border-top: 2px solid var(--primary-gold) !important;
    padding: 10px 15px !important; 
    padding-bottom: max(10px, env(safe-area-inset-bottom)) !important;
    min-height: 60px !important;
    box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.1) !important;
    z-index: 999999 !important; 
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
  }

  .mobile-bottom-bar button {
    background: transparent !important;
    border: none !important;
    font-size: 1.4rem !important;
    color: var(--primary-blue) !important;
    cursor: pointer !important;
    padding: 5px !important;
    transition: transform 0.2s !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  body {
    padding-bottom: 80px !important; 
    padding-bottom: calc(80px + env(safe-area-inset-bottom)) !important; 
  }

  .nav-buttons, 
  .container > .page-card > .slogan-card, 
  .container > .page-card > div[onclick="openDavinaModal()"] {
    display: none !important;
  }

  .mobile-sidebar {
    display: block;
    position: fixed;
    top: 0;
    left: -320px; 
    width: 280px;
    height: 100vh;
    background: var(--bg-color);
    z-index: 2002;
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 4px 0 20px rgba(0,0,0,0.15);
    overflow-y: auto;
    border-right: 2px solid var(--primary-gold);
    padding: 20px;
  }

  .mobile-sidebar.open {
    left: 0;
  }

  .mobile-sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 51, 78, 0.6);
    z-index: 2001;
    backdrop-filter: blur(3px);
  }
  .mobile-sidebar-overlay.show { display: block; }

  .sidebar-header-mobile {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px dashed var(--stroke-strong);
    padding-bottom: 10px;
    margin-bottom: 20px;
  }

  .mobile-slogan p { text-align: left; }
  .mobile-davina-card {
    background: linear-gradient(135deg, rgba(0,51,78,0.03), rgba(212,175,55,0.08));
    border: 1px dashed var(--primary-gold);
    padding: 15px;
  }

  .authors-grid {
    display: flex !important; 
    flex-wrap: nowrap !important;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch; 
    scrollbar-width: none; 
    -ms-overflow-style: none; 
    gap: 15px;
    padding-bottom: 20px; 
    scroll-snap-type: x mandatory; 
  }

  .authors-grid[style*="display: none"],
  .authors-grid[style*="display:none"] {
    display: none !important;
  }

  .authors-grid::-webkit-scrollbar { display: none; }

  .author-card {
    flex: 0 0 240px !important; 
    max-width: 80vw;
    scroll-snap-align: start; 
    touch-action: pan-x pan-y; 
  }
}

/* ==========================================================================
   24. MOBILE SIDEBAR BUTTONS & ACCORDIONS
   ========================================================================== */
.sidebar-btn {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(245, 248, 250, 0.8));
  border: 1px solid rgba(0, 51, 78, 0.2);
  color: var(--primary-blue);
  font-family: 'Acme', cursive;
  font-size: 1.15rem;
  padding: 12px 15px;
  border-radius: 12px;
  cursor: pointer;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.2s;
  box-shadow: 0 4px 6px rgba(0,0,0,0.05);
  width: 100%;
}
.sidebar-btn:hover {
  background: var(--primary-gold);
  color: #12181b;
  border-color: var(--primary-gold);
  transform: translateY(-2px);
}
body.dark-mode .sidebar-btn {
  background: rgba(255,255,255,0.05);
  color: #e0e6ed;
  border-color: rgba(255,255,255,0.1);
}
body.dark-mode .sidebar-btn:hover {
  background: var(--primary-gold);
  color: #12181b;
}

.three-col-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 20px;
  align-items: stretch;
}
@media (max-width: 900px) {
  .three-col-grid {
    display: none; 
    grid-template-columns: 1fr;
  }
  .three-col-grid.open {
    display: grid;
  }
}

.slanted-bg-section {
  position: relative;
  z-index: 1;
  padding: 60px 15px; 
  margin: 40px 0;  
}

@media (max-width: 900px) {
  .slanted-bg-section {
    margin-top: 15px;  
    padding-top: 1px; 
  }
}

.slanted-bg-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(0,51,78,0.85), rgba(212,175,55,0.6));
  transform: skewY(-3deg);
  transform-origin: center;
  z-index: -1;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1); 
  border: 2px solid var(--primary-gold); 
  border-radius: 20px;
}

.vip-badge-icon {
  position: absolute;
  top: 10px;
  right: 10px;
  background: linear-gradient(135deg, var(--primary-gold), #ffdf73);
  color: var(--primary-blue);
  font-weight: bold;
  font-size: 0.85rem;
  padding: 6px 12px;
  border-radius: 20px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
  border: 2px solid white;
  z-index: 20;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
}
.vip-badge-icon:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 15px rgba(0,0,0,0.4);
}

.bestseller-wrapper {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 20px;
}
.bestseller-card {
  background: rgba(255,255,255,0.95);
  border: 2px solid var(--primary-gold);
  border-radius: 12px;
  padding: 15px;
  display: flex;
  gap: 15px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  transition: transform 0.3s ease;
}
.bestseller-card:hover {
  transform: translateY(-3px);
}
.bs-img-wrapper {
  flex-shrink: 0;
  width: 90px;
  height: 135px;
}
.bs-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.bs-content {
  display: flex;
  flex-direction: column;
  flex: 1;
}
.bs-text {
  font-size: 0.95rem;
  color: #444;
  line-height: 1.5;
  margin: 0 0 10px 0;
  flex-grow: 1;
}
.bs-btn {
  background: var(--primary-gold);
  color: var(--primary-blue);
  text-align: center;
  padding: 8px 12px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 0.9rem;
  transition: 0.2s;
  display: block;
}
.bs-btn:hover {
  filter: brightness(0.95);
}

@media (max-width: 900px) {
  .bestseller-wrapper {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 15px; 
    scroll-behavior: smooth;
    -ms-overflow-style: none;
    scrollbar-width: none;
  }
  .bestseller-wrapper::-webkit-scrollbar { display: none; }
  .bestseller-card {
    min-width: 85%; 
    flex-direction: column; 
    align-items: center;
    text-align: center;
    scroll-snap-align: center; 
  }
  .bs-img-wrapper {
    width: 140px;
    height: 210px;
    margin-bottom: 10px;
  }
}

body.dark-mode .bestseller-card {
  background: rgba(30, 40, 50, 0.95) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}
body.dark-mode .bestseller-card .bs-text { color: #b0c4de !important; }
body.dark-mode .bestseller-card h4 { color: var(--primary-gold) !important; }
body.dark-mode .partner-logo { content: url('/data/davina_logo_white.webp'); }

.pub-type-badge,
#modalContent .pub-type-badge {
  background: var(--primary-gold) !important;
  color: #00334e !important; 
  padding: 4px 12px;
  border-radius: 5px;
  font-size: 0.85rem;
  border: 2px solid white;
  display: inline-block;
}

body.dark-mode .pub-type-badge,
body.dark-mode #modalContent .pub-type-badge {
  background: var(--primary-gold) !important;
  color: #12181b !important; 
  border: 2px solid white;
}

body.dark-mode .mobile-bottom-bar {
  background: linear-gradient(180deg, rgba(30, 40, 50, 0.95), rgba(20, 25, 30, 0.98)) !important;
  border-top-color: var(--stroke-strong) !important;
  box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.5) !important;
}

body.dark-mode .mobile-bottom-bar button { color: var(--primary-gold) !important; }
body.dark-mode .mobile-bottom-bar button:hover { color: #fff !important; }

/* ==========================================================================
   25. NEUE TOP NAVIGATION (DESKTOP)
   ========================================================================== */
.global-top-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw; 
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(245, 248, 250, 0.95));
  border-bottom: 2px solid var(--primary-gold);
  box-shadow: 0 4px 15px rgba(0, 51, 78, 0.08);
  z-index: 1000;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  justify-content: center;
}

.top-nav-inner {
  max-width: 1200px;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 20px;
}

.top-nav-brand {
  font-family: 'Great Vibes', cursive;
  font-size: 1.8rem;
  color: var(--primary-gold);
  font-weight: normal;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.05);
}

.top-nav-links { display: flex; gap: 8px; }

.top-nav-links button {
  background: transparent;
  border: none;
  font-family: 'Acme', cursive;
  font-size: 1.15rem;
  color: var(--primary-blue);
  cursor: pointer;
  transition: all 0.2s;
  padding: 5px 12px;
  border-radius: 8px;
}

.top-nav-links button:hover {
  color: var(--primary-gold);
  background: rgba(0, 51, 78, 0.05);
}

.top-nav-actions { display: flex; align-items: center; gap: 15px; }

.theme-toggle-top {
  background: transparent;
  border: none;
  font-size: 1.3rem;
  cursor: pointer;
  transition: transform 0.2s;
}
.theme-toggle-top:hover { transform: scale(1.1); }

.auth-btn-top {
  background: var(--primary-blue);
  color: white;
  border: none;
  font-family: 'Acme', cursive;
  font-size: 1.05rem;
  padding: 6px 16px;
  border-radius: 20px;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
.auth-btn-top:hover { 
  background: var(--primary-gold); 
  color: var(--primary-blue); 
  transform: translateY(-1px);
}

@media (max-width: 900px) {
  .global-top-nav { display: none !important; }
}

/* ==========================================================================
   26. BACK TO TOP BUTTON
   ========================================================================== */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--primary-gold);
  color: var(--primary-blue);
  border: 2px solid white;
  border-radius: 50%;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  opacity: 0;
  pointer-events: none;
  transform: translateY(20px);
  transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  z-index: 1000;
}

.back-to-top.visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--primary-blue);
  color: var(--primary-gold);
  transform: translateY(-3px) scale(1.05);
}

@media (max-width: 900px) {
  .back-to-top {
    bottom: 90px;
    right: 20px;
    width: 45px;
    height: 45px;
    font-size: 1.1rem;
  }
}

body.dark-mode .global-top-nav {
  background: linear-gradient(180deg, rgba(20, 25, 30, 0.98), rgba(30, 40, 50, 0.95)) !important;
  border-bottom-color: rgba(212, 175, 55, 0.4) !important;
}
body.dark-mode .top-nav-links button { color: #e0e6ed !important; }
body.dark-mode .top-nav-links button:hover {
  color: var(--primary-gold) !important;
  background: rgba(255, 255, 255, 0.05) !important;
}
body.dark-mode .auth-btn-top {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #e0e6ed !important;
}
body.dark-mode .auth-btn-top:hover {
  background: var(--primary-gold) !important;
  color: #12181b !important;
}
body.dark-mode .back-to-top {
  background: rgba(30, 40, 50, 0.9);
  color: var(--primary-gold);
  border-color: rgba(255, 255, 255, 0.2);
}
body.dark-mode .back-to-top:hover {
  background: var(--primary-gold);
  color: #12181b;
}

@media (max-width: 900px) {
  .mobile-sidebar {
    padding-bottom: calc(120px + env(safe-area-inset-bottom)) !important;
  }
}

/* --- MAGAZIN TEASER (Startseite) --- */
.magazin-card { background-color: #ffffff; }
.magazin-badge { background-color: var(--primary-blue); color: #ffffff; }
.magazin-title { color: var(--primary-blue); }
.magazin-text { color: #555555; }

body.dark-mode .magazin-card {
  background-color: rgba(30, 40, 50, 0.8) !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}
body.dark-mode .magazin-badge {
  background-color: var(--primary-gold) !important;
  color: var(--primary-blue) !important;
}
body.dark-mode .magazin-title { color: var(--primary-gold) !important; }
body.dark-mode .magazin-text { color: #e0e6ed !important; }

/* ==========================================================================
   27. APP-LAYOUT: MOBILE OPTIMIERUNG
   ========================================================================== */
@media (max-width: 900px) {
  body {
    padding-top: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  .container {
    margin-top: 0 !important;
    padding: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  .page-card.card-style {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    padding: 10px !important; 
  }

  body.dark-mode .page-card.card-style {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
  }

  .card-style {
    padding: 15px !important;
    margin-bottom: 12px !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 10px rgba(0,0,0,0.06) !important; 
  }

  .header-card {
    border-radius: 12px !important;
    margin-bottom: 15px !important;
  }
}

@media (max-width: 600px) {
  .page-card.card-style { padding: 8px 6px !important; }
  .card-style { padding: 12px !important; border-radius: 10px !important; }
  .brand-logo { margin-top: -80px !important; }
}

body.dark-mode #mainBrandLogo {
  content: url('/data/truedark.webp') !important; 
}

/* ==========================================================================
   28. LOKALE SCHRIFTARTEN (DSGVO-KONFORM)
   ========================================================================== */
@font-face {
  font-family: 'Acme';
  font-style: normal;
  font-weight: 400;
  font-display: swap; 
  src: url('/assets/fonts/acme-v27-latin-regular.woff2') format('woff2');
}

@font-face {
  font-family: 'Great Vibes';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/fonts/great-vibes-v21-latin-regular.woff2') format('woff2');
}

body.alt-font {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Ubuntu, "Helvetica Neue", sans-serif !important;
}

body.alt-font .nav-btn, 
body.alt-font .footer-btn, 
body.alt-font .action-btn,
body.alt-font .submit-btn, 
body.alt-font .form-input, 
body.alt-font .form-textarea,
body.alt-font .search-input,
body.alt-font .sidebar-btn,
body.alt-font .switcher-btn,
body.alt-font .close-modal,
body.alt-font .toast-msg,
body.alt-font .top-nav-links button,
body.alt-font .auth-btn-top,
body.alt-font .mtb-btn,
body.alt-font .mobile-filter-toggle {
  font-family: inherit !important;
}

/* ==========================================================================
   29. NATIVE APP HEADER (MOBILE TOP BAR)
   ========================================================================== */
.mobile-top-bar { display: none; }

@media (max-width: 900px) {
  .mobile-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 60px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(245, 248, 250, 0.98));
    border-bottom: 2px solid var(--primary-gold);
    z-index: 1000;
    padding: 0 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
  }

  body { padding-top: 75px !important; }
  .header-card { display: none !important; }

  .mtb-left { display: flex; align-items: center; gap: 10px; cursor: pointer; }
  .mtb-logo {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    object-fit: cover;
    border: 2px solid var(--primary-gold);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  }

  .mtb-brand {
    font-family: 'Great Vibes', cursive;
    font-size: 1.6rem;
    color: var(--primary-blue);
    line-height: 1;
    padding-top: 4px; 
  }

  .mtb-right { display: flex; align-items: center; gap: 12px; }

  .mtb-time {
    font-size: 0.85rem;
    color: #888;
    font-family: monospace;
    font-weight: bold;
    min-width: 80px; 
    text-align: right;
    margin-right: 2px; 
    display: none; 
  }

  @media (min-width: 390px) { .mtb-time { display: block; } }

  .mtb-btn {
    font-family: 'Acme', cursive;
    font-size: 1rem;
    padding: 4px 14px;
    border-radius: 20px;
    border: none;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
  }

  .mtb-login { background: var(--primary-blue); color: white; }
  .mtb-logout { background: #c0392b; color: white; }

  body.dark-mode .mobile-top-bar {
    background: linear-gradient(180deg, rgba(20, 25, 30, 0.95), rgba(30, 40, 50, 0.98));
    border-bottom-color: var(--stroke-strong);
  }
  body.dark-mode .mtb-brand { color: var(--primary-gold); }
  body.dark-mode .mtb-time { color: #aaa; }
  body.dark-mode .mtb-login { background: var(--primary-gold); color: #12181b; }
}

/* ==========================================================================
   30. FAQ AKKORDEON LOGIK
   ========================================================================== */
.faq-item.open .faq-answer { display: block !important; }
.faq-item.open .faq-arrow { transform: rotate(180deg); display: inline-block; }
body.dark-mode .faq-item .faq-answer { color: #b0c4de !important; border-top-color: rgba(255,255,255,0.1) !important; }

/* ==========================================================================
   31. ZUSÄTZLICHE HILFSKLASSEN & MEDIEN
   ========================================================================== */
@media (max-width: 768px) {
  .mobile-filter-toggle {
    display: block;
    width: 100%;
    margin-bottom: 15px;
  }
}

@media (min-width: 901px) {
  .hide-on-desktop { display: none !important; }
}

@media (max-width: 900px) {
  .hide-on-mobile { display: none !important; }
  .mobile-white-title { color: #f0f4f8 !important; }
}

body.dark-mode .mobile-white-title { color: var(--primary-gold) !important; }

.magazin-davina-logo {
  max-width: 140px; 
  margin-bottom: 15px; 
  mix-blend-mode: multiply; 
}

body.dark-mode .magazin-davina-logo {
  mix-blend-mode: normal; 
  content: url('/data/davina_logo_white.webp');
}

.card-footer-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 15px;
  border-top: 1px solid rgba(0,0,0,0.05);
}

body.dark-mode .card-footer-meta {
  border-top: 1px solid rgba(255,255,255,0.05);
}

.view-info { display: flex; align-items: center; gap: 10px; }
.view-count {
  font-size: 0.85rem;
  color: var(--text-color);
  opacity: 0.8;
  display: flex;
  align-items: center;
  gap: 5px;
}

.status-badge {
  font-size: 0.75rem;
  padding: 3px 8px;
  border-radius: 12px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-badge.neu { background: #e0f2fe; color: #0284c7; }
.status-badge.lesenswert { background: #fef08a; color: #854d0e; }
.status-badge.highlight { background: #fee2e2; color: #b91c1c; }

body.dark-mode .status-badge.neu { background: #0c4a6e; color: #7dd3fc; }
body.dark-mode .status-badge.lesenswert { background: #422006; color: #fde047; }
body.dark-mode .status-badge.highlight { background: #450a0a; color: #fca5a5; }

.share-btn {
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  color: var(--primary-gold);
  transition: transform 0.2s;
  padding: 5px;
}
.share-btn:hover { transform: scale(1.15); }

/* ==========================================================================
   APP SUCHE: HYBRID LAYOUT (MOBILE = VOLLBILD, DESKTOP = MODAL)
   ========================================================================== */
.fullscreen-search-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; 
    height: 100dvh; 
    z-index: 9990;
    display: none; 
    flex-direction: column;
    justify-content: center; 
    align-items: center;     
    overflow: hidden;
    background: rgba(10, 40, 60, 0.62); 
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.fullscreen-search-overlay.show-modal { display: flex !important; }

.fullscreen-search-content {
    display: flex;
    flex-direction: column;
    background: var(--bg-color, #ffffff);
    width: 100%;
    height: 100%;
    max-height: 100%; 
    overflow: hidden; 
}

@media (max-width: 900px) {
    .fullscreen-search-overlay {
        background: var(--bg-color, #ffffff); 
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        z-index: 9990; 
        justify-content: flex-start;
        align-items: stretch;
    }
}

@media (min-width: 901px) {
    .fullscreen-search-content {
        width: min(1000px, 100%);
        height: 85vh; 
        border-radius: 15px;
        border: 1px solid rgba(212, 175, 55, 0.55);
        box-shadow: 0 22px 60px rgba(0, 0, 0, 0.25);
        animation: popUp 0.3s ease-out;
    }
}

.fs-header {
    display: flex; justify-content: space-between; align-items: center;
    padding: 15px 20px;
    border-bottom: 2px solid var(--primary-gold);
    background: var(--bg-color, #ffffff);
}
@media (min-width: 901px) {
    .fs-header { border-top-left-radius: 15px; border-top-right-radius: 15px; }
}

.fs-header h2 { margin: 0; color: var(--primary-blue); font-size: 1.5rem; font-family: 'Great Vibes', cursive; font-weight: normal; }
.fs-header button { background: none; border: none; font-size: 1.8rem; color: var(--primary-blue); cursor: pointer; padding: 0; line-height: 1; }

.fs-filters {
    padding: 15px;
    display: flex; flex-direction: column; gap: 12px;
    background: rgba(0, 51, 78, 0.03);
    border-bottom: 1px solid #eee;
}

.fs-tabs { display: flex; gap: 10px; flex-wrap: wrap; }
.fs-tab { 
    flex: 1; padding: 8px 5px; 
    border: 1px solid var(--primary-gold); 
    background: transparent; color: var(--primary-blue); 
    border-radius: 5px; cursor: pointer; font-size: 0.9rem; font-weight: bold; transition: 0.2s;
    min-width: 80px; text-align: center;
}
.fs-tab.active { background: var(--primary-gold); color: var(--primary-blue); }

.fs-dropdowns { display: flex; gap: 10px; }
.fs-dropdowns select { flex: 1; padding: 10px; background: #fff; cursor: pointer; border: 1px solid #ccc; font-size: 0.95rem; }

.fs-results {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
    display: flex; flex-direction: column; gap: 12px;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 50px;
}

.fs-card {
    display: flex; align-items: center; padding: 10px 15px; gap: 15px;
    background: var(--card-bg, #ffffff);
    border: 1px solid #eee; border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    cursor: pointer; transition: 0.2s;
}
.fs-card:active { transform: scale(0.98); background: #fafafa; }

.fs-card-img-book { 
    width: 50px; height: 75px; border-radius: 4px; object-fit: cover; border: 1px solid #ccc; flex-shrink: 0; 
}
.fs-card-img-book-placeholder { 
    width: 50px; height: 75px; border-radius: 4px; background: #eee; display: flex; align-items: center; justify-content: center; font-size: 0.8rem; border: 1px solid #ccc; flex-shrink: 0; color: #999; 
}

.fs-card-img { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; border: 2px solid var(--primary-gold); flex-shrink: 0; }
.fs-card-img-placeholder { width: 60px; height: 50px; border-radius: 50%; background: #eee; display: flex; align-items: center; justify-content: center; font-size: 1rem; border: 2px solid var(--primary-gold); flex-shrink: 0; color: #999; font-weight: bold;}

.fs-card-info { flex: 1; display: flex; flex-direction: column; justify-content: center; overflow: hidden; }
.fs-card-name { font-weight: bold; color: var(--primary-blue); font-size: 1.05rem; margin-bottom: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.fs-card-badge { display: inline-block; padding: 3px 8px; font-size: 0.7rem; border-radius: 12px; font-weight: bold; width: fit-content; text-transform: uppercase; letter-spacing: 0.5px;}
.badge-author { background: rgba(0,51,78,0.1); color: var(--primary-blue); border: 1px solid var(--primary-blue); }
.badge-blogger { background: rgba(212,175,55,0.2); color: #8a6d1c; border: 1px solid var(--primary-gold); }
.badge-both { background: linear-gradient(135deg, rgba(0,51,78,0.1), rgba(212,175,55,0.2)); color: var(--primary-blue); border: 1px solid var(--primary-gold); }

.mobile-sidebar { z-index: 10005 !important; }
.mobile-sidebar-overlay { z-index: 10000 !important; }

/* ==========================================================================
   APP SUCHE: DUNKELMODUS (DARK MODE OVERRIDES)
   ========================================================================== */
body.dark-mode .fullscreen-search-overlay { background: rgba(0, 0, 0, 0.8) !important; }

body.dark-mode .fullscreen-search-content {
    background: linear-gradient(135deg, rgba(30, 40, 50, 0.98) 0%, rgba(20, 25, 30, 0.98) 100%) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}

body.dark-mode .fs-header {
    background: transparent !important;
    border-bottom-color: rgba(212, 175, 55, 0.4) !important;
}

body.dark-mode .fs-header h2 { color: var(--primary-gold) !important; }
body.dark-mode .fs-header button { color: var(--primary-gold) !important; }

body.dark-mode .fs-filters {
    background: rgba(0, 0, 0, 0.2) !important;
    border-bottom-color: rgba(255, 255, 255, 0.1) !important;
}

body.dark-mode .fs-tab {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #e0e6ed !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
}

body.dark-mode .fs-tab:hover {
    border-color: var(--primary-gold) !important;
    color: var(--primary-gold) !important;
}

body.dark-mode .fs-tab.active {
    background: var(--primary-gold) !important;
    color: #12181b !important;
    border-color: var(--primary-gold) !important;
}

body.dark-mode .fs-card {
    background: rgba(255, 255, 255, 0.05) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}

body.dark-mode .fs-card:active { background: rgba(0, 0, 0, 0.3) !important; }
body.dark-mode .fs-card-name { color: var(--primary-gold) !important; }

body.dark-mode .fs-card-img-placeholder,
body.dark-mode .fs-card-img-book-placeholder {
    background: rgba(0, 0, 0, 0.3) !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    color: #b0c4de !important;
}

body.dark-mode .fs-dropdowns select {
    background: rgba(0, 0, 0, 0.3) !important;
    color: #e0e6ed !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
}

/* ==========================================================================
   FIX: LESEBARKEIT SEMI-TRANSPARENTER CARDS AUF MOBILE (LIGHT MODE)
   ========================================================================== */
@media (max-width: 900px) {
  body:not(.dark-mode) .card-style[style*="rgba(192, 57, 43, 0.1)"] { background: #fdf2f2 !important; }
  
  body:not(.dark-mode) .card-style[style*="rgba(212,175,55,0.1)"],
  body:not(.dark-mode) .card-style[style*="rgba(212, 175, 55, 0.1)"],
  body:not(.dark-mode) div[style*="background: rgba(212, 175, 55, 0.1)"] {
    background: #fdfbf4 !important;
  }
  
  body:not(.dark-mode) .card-style[style*="rgba(0, 51, 78, 0.05)"],
  body:not(.dark-mode) div[style*="background: rgba(0,51,78,0.05)"],
  body:not(.dark-mode) div[style*="background: rgba(0, 51, 78, 0.05)"] {
    background: #f2f6f9 !important;
  }

  body:not(.dark-mode) .flash-message[style*="rgba(0,128,0,0.1)"] { background: #f0fdf4 !important; }
  
  body:not(.dark-mode) .card-style[style*="rgba(255,255,255,0.85)"],
  body:not(.dark-mode) .card-style[style*="rgba(255,255,255,0.7)"],
  body:not(.dark-mode) div[style*="background: rgba(255,255,255,0.7)"],
  body:not(.dark-mode) .blog-tools {
    background: #ffffff !important;
  }

  body.dark-mode .card-style[style*="rgba(255,255,255,0.85)"],
  body.dark-mode .card-style[style*="rgba(255,255,255,0.7)"],
  body.dark-mode div[style*="background: rgba(255,255,255,0.7)"] {
    background: rgba(255, 255, 255, 0.05) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
  }
}

/* ==========================================================================
   MOBILE FEINSCHLIFF (Überschreibungen für Handys)
   ========================================================================== */
@media (max-width: 900px) {
    .settings-header .chevron,
    .accordion-title::after,
    .mobile-accordion-header::after {
        display: none !important;
    }

    .settings-card,
    .settings-card .section-title {
        text-align: left !important;
    }

    .card-style, 
    .page-card.card-style, 
    .book-edit-card,
    .new-book-card {
        border-radius: 8px !important;
    }

    .settings-header:hover {
        border-bottom-color: transparent !important;
    }
    
    .collapsed .section-title,
    .settings-header .section-title {
        border-bottom: none !important;
    }
}


/* ======================================================================
   ENTERPRISE STYLES: TRUEPUBLISHING & TRUEALL
   ====================================================================== */

/* Utilities & Layout */
.hidden { display: none !important; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; justify-content: space-between; align-items: center; }
.w-100 { width: 100%; }
.mt-0 { margin-top: 0; }
.mb-5 { margin-bottom: 5px; }
.mb-10 { margin-bottom: 10px; }
.mb-15 { margin-bottom: 15px; }
.mb-20 { margin-bottom: 20px; }
.mb-25 { margin-bottom: 25px; }
.text-center { text-align: center; }
.text-left { text-align: left; }

/* Typografie */
.title-gold { color: var(--primary-gold); border-bottom: 2px solid #eee; padding-bottom: 10px; font-size: 1.3rem; }
.title-blue { color: var(--primary-blue); font-size: 1.4rem; }
.sub-text { color: #666; font-size: 0.9rem; line-height: 1.5; }
.great-vibes { font-family: 'Great Vibes', cursive; font-weight: normal; }

/* Buttons & Hovers (Ersetzt onmouseover / onmouseout) */
.hero-btn-discover { flex: 1 1 auto; min-width: 220px; max-width: 280px; padding: 15px; font-size: 1.1rem; box-shadow: 0 4px 10px rgba(0,0,0,0.1); transition: transform 0.2s, box-shadow 0.2s; }
.hero-btn-discover:hover { transform: translateY(-3px); box-shadow: 0 6px 15px rgba(0,0,0,0.15); }

.hero-btn-register { flex: 1 1 auto; min-width: 220px; max-width: 280px; padding: 15px; font-size: 1.1rem; background: var(--primary-gold); color: var(--primary-blue); border: none; font-weight: bold; box-shadow: 0 4px 15px rgba(212,175,55,0.4); transition: transform 0.2s, box-shadow 0.2s; }
.hero-btn-register:hover { transform: translateY(-3px); box-shadow: 0 8px 20px rgba(212,175,55,0.6); }

/* Promo Cards */
.promo-blog-card { background: linear-gradient(135deg, rgba(0,51,78,0.85), rgba(212,175,55,0.6)); border: 1px solid var(--primary-gold); border-radius: 12px; box-shadow: 0 4px 10px rgba(0,0,0,0.1); }
.promo-blog-card .action-btn { background-color: #ffffff; color: var(--primary-blue); border: none; box-shadow: 0 2px 5px rgba(0,0,0,0.2); transition: transform 0.3s; }
.promo-blog-card .action-btn:hover { transform: scale(1.02); }

.promo-webdesign-card { background: linear-gradient(135deg, var(--primary-blue), #001f30); border: 2px solid var(--primary-gold); border-radius: 12px; box-shadow: 0 8px 25px rgba(0,0,0,0.25); position: relative; overflow: hidden; }
.promo-webdesign-card .bg-icon { position: absolute; top: -15px; right: -10px; font-size: 8rem; opacity: 0.05; pointer-events: none; }
.promo-webdesign-card .btn-primary { background-color: var(--primary-gold); color: var(--primary-blue); border: none; box-shadow: 0 4px 10px rgba(0,0,0,0.3); transition: transform 0.3s; }
.promo-webdesign-card .btn-primary:hover { transform: translateY(-2px); }
.promo-webdesign-card .btn-secondary { border-color: #ffffff; color: #ffffff; transition: background 0.3s; }
.promo-webdesign-card .btn-secondary:hover { background: rgba(255,255,255,0.1); }

/* Davina Card */
.davina-partner-card { background: linear-gradient(135deg, rgba(0,51,78,0.03), rgba(212,175,55,0.08)); border: 1px dashed var(--primary-gold); cursor: pointer; transition: filter 0.3s; }
.davina-partner-card:hover { filter: brightness(0.95); }
.davina-social-btn { display: inline-flex; align-items: center; justify-content: center; width: 45px; height: 45px; background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); border-radius: 50%; color: white; text-decoration: none; box-shadow: 0 4px 10px rgba(0,0,0,0.15); transition: transform 0.2s; }
.davina-social-btn:hover { transform: scale(1.1); }

/* Bestseller / Reviews Text Toggle */
.bs-text { max-height: 90px; overflow: hidden; transition: max-height 0.3s ease-in-out; margin-bottom: 5px; }
.bs-toggle-btn { cursor: pointer; color: var(--primary-gold); font-size: 0.85rem; font-weight: bold; display: inline-block; margin-bottom: 10px; }

/* 1. Fix für die Genre-Tags in der Buch-Detailansicht (die blauen Pillen) */
body.dark-mode #modalContent .selected-genre-tag {
    background-color: rgba(255, 255, 255, 0.15) !important; /* Etwas helleres Blau/Grau */
    color: #ffffff !important; /* Reinweiß für besten Kontrast */
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
    font-weight: bold !important;
}

/* 2. Fix für die Tags im Autoren-Profil (die gelben/dunklen Badges), 
   falls diese Klasse dort anders verwendet wird */
body.dark-mode #modalContent .selected-tag {
    color: #ffffff !important; 
    background: rgba(0, 51, 78, 0.9) !important;
    border: 1px solid var(--primary-gold) !important;
}

/* ==========================================================================
   MODERNE BEWERTUNGSSKALA (Sterne & Balken)
   ========================================================================== */

/* --- Sterne für die Gesamtbewertung --- */
.modern-rating-stars {
  display: inline-flex;
  gap: 4px;
  align-items: center;
}

.star-icon {
  width: 22px;
  height: 22px;
  fill: rgba(0, 51, 78, 0.15); /* Dezentes Blau für inaktive Sterne */
  transition: transform 0.2s ease, fill 0.3s ease, filter 0.3s ease;
}

.star-icon.active {
  fill: var(--primary-gold);
  filter: drop-shadow(0 2px 5px rgba(212, 175, 55, 0.4));
}

/* Hover-Effekt (optional, macht es etwas dynamischer) */
@media (hover: hover) {
  .modern-rating-stars:hover .star-icon.active {
    transform: scale(1.05);
  }
}

/* --- Segment-Balken für die Detailbewertung --- */
.modern-rating-bar {
  display: flex;
  gap: 5px;
  align-items: center;
}

.rating-segment {
  width: 18px; /* Breite jedes einzelnen Blocks */
  height: 6px; /* Höhe des Blocks */
  background: rgba(0, 51, 78, 0.1);
  border-radius: 4px; /* Abgerundete "Pillen"-Form */
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.rating-segment.active {
  background: var(--primary-gold);
  box-shadow: 0 0 6px rgba(212, 175, 55, 0.3);
}

/* --- Dark Mode Anpassungen --- */
body.dark-mode .star-icon {
  fill: rgba(255, 255, 255, 0.15);
}

body.dark-mode .star-icon.active {
  fill: var(--primary-gold);
}

body.dark-mode .rating-segment {
  background: rgba(255, 255, 255, 0.1);
}

body.dark-mode .rating-segment.active {
  background: var(--primary-gold);
}

/* Abstandsanpassung im Rezensions-Modal (optional, falls es zu eng wirkt) */
.js-jump-blogger-review .modern-rating-stars {
  margin-top: 5px;
}
/* ==========================================================================
   FIX: ZURÜCK-PFEIL OBEN LINKS, TITEL DARUNTER
   ========================================================================== */

/* Den Pfeil absolut oben links fixieren */
#modalBackBtn {
    position: absolute !important;
    top: 20px !important; 
    left: 20px !important;
    z-index: 9999 !important;
    background: transparent !important;
    border: none !important;
    padding: 10px !important; 
    line-height: 1 !important;
}

/* Den Titel nach unten schieben, damit er unter den Buttons beginnt */
#modalTitle {
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-top: 40px !important; /* Schafft den nötigen Platz nach oben */
    display: block;
}

/* Anpassung für kleinere Handys */
@media (max-width: 600px) {
    #modalBackBtn {
        top: 10px !important;
        left: 10px !important;
    }
    #modalTitle {
        margin-top: 45px !important; /* Auf ganz kleinen Screens etwas mehr Puffer */
    }
}
/* --- MODAL NAVIGATION (Pfeile außerhalb der Karte) --- */
.modal-nav-btn {
  /* Desktop-Ansicht: Sitzen natürlich im Flex-Layout neben der Karte */
  position: relative;
  flex-shrink: 0; /* Verhindert, dass die Buttons gequetscht werden */
  margin: 0 200px; /* Abstand zur Karte */
  width: 50px;
  height: 50px;
  background: var(--primary-gold);
  color: var(--primary-blue);
  border: 2px solid #fff;
  border-radius: 50%;
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10000;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  transition: all 0.2s ease;
}

@media (hover: hover) {
  .modal-nav-btn:hover {
    background: var(--primary-blue);
    color: var(--primary-gold);
    border-color: var(--primary-gold);
    transform: scale(1.1); /* Zoom ohne translateY, da wir kein absolute mehr nutzen */
  }
}

/* Dark Mode */
body.dark-mode .modal-nav-btn {
  background: rgba(30, 40, 50, 0.9);
  color: var(--primary-gold);
  border-color: rgba(255, 255, 255, 0.2);
}
body.dark-mode .modal-nav-btn:hover {
  background: var(--primary-gold);
  color: #12181b;
}

/* Mobile Anpassung: Ab 900px absolut am Rand, da sonst der Platz fehlt */
@media (max-width: 900px) {
  .modal-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    margin: 0;
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
  }
  .prev-btn { left: 5px; }
  .next-btn { right: 5px; }
}

/* Stellt sicher, dass die Bilder genau so groß sind wie vorher die Emojis */
.nav-icon {
    width: 24px;
    height: 24px;
    object-fit: contain; /* Verhindert, dass die Bilder verzerrt werden */
    vertical-align: middle; /* Richtet das Bild schön mittig im Button aus */
}

/* LIGHT MODE (Standard): Hamburger-Menü ist dunkel (passend zu den schwarzen PNGs) */
.mobile-bottom-bar .js-toggle-sidebar span {
    color: #111; /* Deine normale Textfarbe im hellen Modus */
    transition: color 0.3s ease;
}

.nav-icon {
    /* Weicher Übergang beim Wechseln des Modus */
    transition: filter 0.3s ease; 
}

/* ========================================= */
/* DARK MODE ANPASSUNGEN                     */
/* ========================================= */

/* 1. Hamburger-Menü wird gold/gelb */
body.dark-mode .mobile-bottom-bar .js-toggle-sidebar span {
    color: var(--primary-gold, #D4AF37); /* Nutzt dein TruePublishing-Gold */
}

/* 2. Die schwarzen PNG-Icons werden per Filter exakt in dieses Gold umgefärbt */
body.dark-mode .nav-icon {
    /* Diese magische Filter-Kombination wandelt reines Schwarz in ~ #D4AF37 (Gold) um */
    filter: invert(73%) sepia(34%) saturate(834%) hue-rotate(359deg) brightness(91%) contrast(89%);
}

/* Styling für echte Profilbilder in der Navigation */
.nav-profile-img {
    width: 32px;
    height: 32px;
    border-radius: 50%;           /* Macht das Bild perfekt rund */
    object-fit: cover;            /* Verhindert, dass das Gesicht verzerrt wird */
    border: 1px solid var(--primary-gold, #D4AF37); /* Ein schicker goldener Rand */
    transition: transform 0.2s;
}

/* WICHTIG: Kein Filter für das Profilbild im Dark Mode! */
body.dark-mode .nav-profile-img {
    filter: none; 
}

/* Zuweisung mit dem korrekten Pfad */
.icon-home     { background-image: url('/../data/zuhause.png'); }
.icon-darkmode { background-image: url('/../data/mond.png'); }
.icon-font     { background-image: url('/../data/buchstabe.png'); }
.icon-idea     { background-image: url('/../data/idee.png'); }
.icon-notes    { background-image: url('/../data/schreiben.png'); }
.icon-profile  { background-image: url('/../data/login.png'); }
.icon-contact  { background-image: url('/../data/brief.png'); }
.icon-search   { background-image: url('/../data/lupe.png'); }