/* ============================================================
   ABNEHMCHAT – bbPress Forum Styling
   Basiert auf echter bbPress HTML-Ausgabe (analysiert anhand Screenshot)
   
   Echte bbPress Struktur auf /forum/:
   
   #bbpress-forums
     div.bbp-forum-content  (oder direkt ul)
       ul.bbp-forums         ← eine pro Kategorie
         li.bbp-header       ← "Forum | Topics | Posts | Last Post"
           span.bbp-forum-info
           span.bbp-forum-topic-count
           span.bbp-forum-reply-count  
           span.bbp-forum-freshness
         li.bbp-forum        ← jedes Sub-Forum
           div.bbp-forum-info
             a.bbp-forum-title
             p.bbp-forum-content (Beschreibung)
           p.bbp-forum-topic-count
           p.bbp-forum-reply-count
           p.bbp-forum-freshness
             a (letzter Beitrag-Link)
             span.bbp-author-name
   ============================================================ */

/* ─── Reset & Basis ──────────────────────────────────────── */
#bbpress-forums,
#bbpress-forums * {
  box-sizing: border-box !important;
}

#bbpress-forums {
  font-family: 'Open Sans', 'Segoe UI', sans-serif !important;
}

/* Alle Listen-Defaults entfernen */
#bbpress-forums ul.bbp-forums,
#bbpress-forums ul.bbp-topics,
#bbpress-forums ul.bbp-replies {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* ─── Suchleiste ─────────────────────────────────────────── */
#bbp-search-form {
  display: flex !important;
  gap: 0 !important;
  margin-bottom: 24px !important;
}

#bbp-search-form input[type="text"],
#bbp-search-form input[name="bbps"] {
  flex: 1 !important;
  padding: 10px 16px !important;
  border: 2px solid #c8dfc9 !important;
  border-right: none !important;
  border-radius: 8px 0 0 8px !important;
  font-size: .9rem !important;
  outline: none !important;
  background: #fff !important;
  color: #2c3e50 !important;
  transition: border-color .2s !important;
}

#bbp-search-form input[type="text"]:focus { border-color: #2e7d32 !important; }

#bbp-search-form input[type="submit"],
#bbp-search-form button[type="submit"] {
  padding: 10px 20px !important;
  background: #2e7d32 !important;
  color: #fff !important;
  border: none !important;
  border-radius: 0 8px 8px 0 !important;
  font-weight: 700 !important;
  font-size: .9rem !important;
  cursor: pointer !important;
  transition: background .2s !important;
}

#bbp-search-form input[type="submit"]:hover,
#bbp-search-form button[type="submit"]:hover {
  background: #1b5e20 !important;
}

/* ─── Breadcrumb ─────────────────────────────────────────── */
#bbpress-forums .bbp-breadcrumb { margin-bottom: 14px !important; }
#bbpress-forums .bbp-breadcrumb p { font-size: .84rem !important; color: #5d7286 !important; margin: 0 !important; }
#bbpress-forums .bbp-breadcrumb a { color: #2e7d32 !important; text-decoration: none !important; }
#bbpress-forums .bbp-breadcrumb a:hover { text-decoration: underline !important; }

/* ═══════════════════════════════════════════════════════════
   FORUM-ÜBERSICHT  ul.bbp-forums
   
   bbPress gibt für jede Kategorie EINE ul.bbp-forums aus.
   Darin: li.bbp-header + mehrere li.bbp-forum (Sub-Foren)
   
   Spalten: [Forum-Info] [Topics] [Posts] [Last Post]
   ═══════════════════════════════════════════════════════════ */

/* Jede Kategorie-Tabelle */
#bbpress-forums ul.bbp-forums {
  display: table !important;
  width: 100% !important;
  border-collapse: collapse !important;
  background: #fff !important;
  border-radius: 12px !important;
  box-shadow: 0 2px 16px rgba(46,125,50,.10) !important;
  border: 1px solid #c8dfc9 !important;
  margin-bottom: 24px !important;
  overflow: hidden !important;
}

/* ── Header-Zeile ────────────────────────────────────────── */
#bbpress-forums ul.bbp-forums li.bbp-header {
  display: table-row !important;
  background: #e8f5e9 !important;
  list-style: none !important;
}

#bbpress-forums ul.bbp-forums li.bbp-header span {
  display: table-cell !important;
  padding: 9px 16px !important;
  font-size: .7rem !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: .07em !important;
  color: #5d7286 !important;
  border-bottom: 2px solid #c8dfc9 !important;
  white-space: nowrap !important;
  vertical-align: middle !important;
}

/* Die drei Zahl-Spalten rechtsbündig/zentriert */
#bbpress-forums ul.bbp-forums li.bbp-header span.bbp-forum-topic-count,
#bbpress-forums ul.bbp-forums li.bbp-header span.bbp-forum-reply-count {
  text-align: center !important;
  width: 80px !important;
}

#bbpress-forums ul.bbp-forums li.bbp-header span.bbp-forum-freshness {
  width: 200px !important;
}

/* ── Forum-Zeilen ────────────────────────────────────────── */
#bbpress-forums ul.bbp-forums li.bbp-forum {
  display: table-row !important;
  list-style: none !important;
  background: #fff !important;
  transition: background .15s !important;
}

#bbpress-forums ul.bbp-forums li.bbp-forum:hover {
  background: #f1f8f2 !important;
}

/* Trennlinie zwischen Zeilen */
#bbpress-forums ul.bbp-forums li.bbp-forum + li.bbp-forum {
  border-top: 1px solid #e0ede1 !important;
}

/* Alle Zellen in einer Forum-Zeile */
#bbpress-forums ul.bbp-forums li.bbp-forum > div,
#bbpress-forums ul.bbp-forums li.bbp-forum > p {
  display: table-cell !important;
  vertical-align: middle !important;
  padding: 13px 16px !important;
}

/* ── Spalte 1: Forum-Info ─────────────────────────────────── */
#bbpress-forums ul.bbp-forums li.bbp-forum .bbp-forum-info {
  display: table-cell !important;
  vertical-align: middle !important;
  padding: 13px 16px !important;
}

/* Icon-Kreis */
#bbpress-forums ul.bbp-forums li.bbp-forum .bbp-forum-info {
  position: relative !important;
  padding-left: 16px !important;
}

/* Innerer Flex-Container für Icon + Text */
#bbpress-forums ul.bbp-forums li.bbp-forum .bbp-forum-info-content {
  display: flex !important;
  align-items: flex-start !important;
  gap: 12px !important;
}

/* Forum-Icon (Emoji davor) – via CSS ::before */
#bbpress-forums ul.bbp-forums li.bbp-forum .bbp-forum-info::before {
  content: '⚖️' !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 38px !important;
  height: 38px !important;
  min-width: 38px !important;
  background: linear-gradient(135deg, #2e7d32 0%, #1b5e20 100%) !important;
  border-radius: 50% !important;
  font-size: 1rem !important;
  margin-right: 12px !important;
  vertical-align: middle !important;
  line-height: 38px !important;
  text-align: center !important;
  flex-shrink: 0 !important;
}

/* Forum-Titel */
#bbpress-forums ul.bbp-forums li.bbp-forum .bbp-forum-info a.bbp-forum-title,
#bbpress-forums ul.bbp-forums li.bbp-forum .bbp-forum-info > a {
  font-weight: 700 !important;
  font-size: .95rem !important;
  color: #1a2e1b !important;
  text-decoration: none !important;
  display: inline-block !important;
  margin-bottom: 3px !important;
  line-height: 1.3 !important;
}

#bbpress-forums ul.bbp-forums li.bbp-forum .bbp-forum-info a.bbp-forum-title:hover,
#bbpress-forums ul.bbp-forums li.bbp-forum .bbp-forum-info > a:hover {
  color: #2e7d32 !important;
  text-decoration: underline !important;
}

/* Forum-Beschreibung */
#bbpress-forums ul.bbp-forums li.bbp-forum .bbp-forum-info p.bbp-forum-content,
#bbpress-forums ul.bbp-forums li.bbp-forum p.bbp-forum-content {
  display: block !important;
  font-size: .79rem !important;
  color: #5a7a5c !important;
  margin: 2px 0 0 !important;
  line-height: 1.45 !important;
}

/* ── Spalte 2: Topics ────────────────────────────────────── */
#bbpress-forums ul.bbp-forums li.bbp-forum p.bbp-forum-topic-count {
  display: table-cell !important;
  vertical-align: middle !important;
  text-align: center !important;
  width: 80px !important;
  font-weight: 700 !important;
  font-size: .92rem !important;
  color: #2c3e50 !important;
  padding: 13px 8px !important;
  white-space: nowrap !important;
}

/* ── Spalte 3: Posts ─────────────────────────────────────── */
#bbpress-forums ul.bbp-forums li.bbp-forum p.bbp-forum-reply-count {
  display: table-cell !important;
  vertical-align: middle !important;
  text-align: center !important;
  width: 80px !important;
  font-weight: 700 !important;
  font-size: .92rem !important;
  color: #2c3e50 !important;
  padding: 13px 8px !important;
  white-space: nowrap !important;
}

/* ── Spalte 4: Last Post ─────────────────────────────────── */
#bbpress-forums ul.bbp-forums li.bbp-forum p.bbp-forum-freshness {
  display: table-cell !important;
  vertical-align: middle !important;
  width: 200px !important;
  padding: 13px 16px !important;
  font-size: .79rem !important;
  color: #5a7a5c !important;
  line-height: 1.55 !important;
}

#bbpress-forums ul.bbp-forums li.bbp-forum p.bbp-forum-freshness a {
  color: #2e7d32 !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  display: block !important;
  margin-bottom: 1px !important;
  font-size: .79rem !important;
}

#bbpress-forums ul.bbp-forums li.bbp-forum p.bbp-forum-freshness a:hover {
  text-decoration: underline !important;
}

/* Footer-Zeile */
#bbpress-forums ul.bbp-forums li.bbp-footer {
  display: table-row !important;
  list-style: none !important;
  background: #e8f5e9 !important;
}

#bbpress-forums ul.bbp-forums li.bbp-footer p {
  display: table-cell !important;
  padding: 8px 16px !important;
  font-size: .78rem !important;
  color: #5a7a5c !important;
}

/* ═══════════════════════════════════════════════════════════
   THEMEN-LISTE  ul.bbp-topics
   ═══════════════════════════════════════════════════════════ */

#bbpress-forums ul.bbp-topics {
  display: table !important;
  width: 100% !important;
  border-collapse: collapse !important;
  background: #fff !important;
  border-radius: 12px !important;
  box-shadow: 0 2px 16px rgba(46,125,50,.10) !important;
  border: 1px solid #c8dfc9 !important;
  margin-bottom: 24px !important;
}

#bbpress-forums ul.bbp-topics li.bbp-header {
  display: table-row !important;
  background: #e8f5e9 !important;
  list-style: none !important;
}

#bbpress-forums ul.bbp-topics li.bbp-header span {
  display: table-cell !important;
  padding: 9px 16px !important;
  font-size: .7rem !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: .07em !important;
  color: #5d7286 !important;
  border-bottom: 2px solid #c8dfc9 !important;
  white-space: nowrap !important;
  vertical-align: middle !important;
}

#bbpress-forums ul.bbp-topics li.bbp-header span.bbp-topic-voice-count,
#bbpress-forums ul.bbp-topics li.bbp-header span.bbp-topic-reply-count {
  text-align: center !important;
  width: 80px !important;
}

#bbpress-forums ul.bbp-topics li.bbp-header span.bbp-topic-freshness {
  width: 200px !important;
}

#bbpress-forums ul.bbp-topics li.bbp-topic {
  display: table-row !important;
  list-style: none !important;
  background: #fff !important;
  transition: background .15s !important;
}

#bbpress-forums ul.bbp-topics li.bbp-topic:hover { background: #f1f8f2 !important; }

#bbpress-forums ul.bbp-topics li.bbp-topic + li.bbp-topic {
  border-top: 1px solid #e0ede1 !important;
}

#bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-title {
  display: table-cell !important;
  vertical-align: middle !important;
  padding: 12px 16px !important;
}

#bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-title a {
  font-weight: 600 !important;
  font-size: .9rem !important;
  color: #1a2e1b !important;
  text-decoration: none !important;
}

#bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-title a:hover {
  color: #2e7d32 !important;
  text-decoration: underline !important;
}

#bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-voice-count,
#bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-reply-count {
  display: table-cell !important;
  vertical-align: middle !important;
  text-align: center !important;
  width: 80px !important;
  font-weight: 700 !important;
  font-size: .9rem !important;
  color: #2c3e50 !important;
  padding: 12px 8px !important;
}

#bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-freshness {
  display: table-cell !important;
  vertical-align: middle !important;
  width: 200px !important;
  padding: 12px 16px !important;
  font-size: .79rem !important;
  color: #5a7a5c !important;
  line-height: 1.55 !important;
}

#bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-freshness a {
  color: #2e7d32 !important;
  font-weight: 600 !important;
  font-size: .79rem !important;
  text-decoration: none !important;
  display: block !important;
  margin-bottom: 1px !important;
}

#bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-freshness a:hover {
  text-decoration: underline !important;
}

#bbpress-forums ul.bbp-topics li.bbp-footer {
  display: table-row !important;
  list-style: none !important;
  background: #e8f5e9 !important;
}

#bbpress-forums ul.bbp-topics li.bbp-footer p {
  display: table-cell !important;
  padding: 8px 16px !important;
  font-size: .78rem !important;
  color: #5a7a5c !important;
}

/* ═══════════════════════════════════════════════════════════
   ANTWORTEN  ul.bbp-replies
   ═══════════════════════════════════════════════════════════ */

#bbpress-forums ul.bbp-replies {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 0 20px !important;
  background: #fff !important;
  border-radius: 12px !important;
  box-shadow: 0 2px 16px rgba(46,125,50,.10) !important;
  border: 1px solid #c8dfc9 !important;
  overflow: hidden !important;
}

#bbpress-forums ul.bbp-replies li.bbp-reply {
  list-style: none !important;
  border-bottom: 1px solid #e0ede1 !important;
  display: flex !important;
  margin: 0 !important;
  padding: 0 !important;
  background: #fff !important;
}

#bbpress-forums ul.bbp-replies li.bbp-reply:last-child { border-bottom: none !important; }

#bbpress-forums ul.bbp-replies li.bbp-reply .bbp-reply-author {
  min-width: 110px !important;
  width: 110px !important;
  flex-shrink: 0 !important;
  padding: 16px 12px !important;
  text-align: center !important;
  border-right: 1px solid #e0ede1 !important;
  background: #f4f6f4 !important;
}

#bbpress-forums ul.bbp-replies li.bbp-reply .bbp-reply-author img {
  border-radius: 50% !important;
  border: 3px solid #c8dfc9 !important;
  margin: 0 auto 8px !important;
  display: block !important;
}

#bbpress-forums ul.bbp-replies li.bbp-reply .bbp-reply-author .bbp-author-name {
  font-weight: 700 !important;
  font-size: .82rem !important;
  color: #2e7d32 !important;
}

#bbpress-forums ul.bbp-replies li.bbp-reply .bbp-reply-content {
  flex: 1 !important;
  padding: 16px 18px !important;
  font-size: .9rem !important;
  line-height: 1.7 !important;
  color: #2c3e50 !important;
}

#bbpress-forums ul.bbp-replies li.bbp-reply .bbp-reply-content blockquote {
  border-left: 4px solid #2e7d32 !important;
  background: #e8f5e9 !important;
  padding: 10px 14px !important;
  margin: 10px 0 !important;
  border-radius: 0 8px 8px 0 !important;
  color: #5d7286 !important;
  font-style: italic !important;
}

/* ═══════════════════════════════════════════════════════════
   FORMULARE
   ═══════════════════════════════════════════════════════════ */

#bbpress-forums #new-post,
#bbpress-forums form.bbp-topic-form,
#bbpress-forums form.bbp-reply-form {
  background: #fff !important;
  border-radius: 12px !important;
  box-shadow: 0 2px 16px rgba(46,125,50,.10) !important;
  padding: 22px !important;
  margin: 20px 0 !important;
  border: 1px solid #c8dfc9 !important;
}

#bbpress-forums fieldset { border: none !important; padding: 0 !important; margin-bottom: 14px !important; }
#bbpress-forums fieldset legend { font-weight: 700 !important; font-size: .85rem !important; color: #2c3e50 !important; margin-bottom: 5px !important; }

#bbpress-forums fieldset input[type="text"],
#bbpress-forums fieldset textarea,
#bbpress-forums fieldset select {
  width: 100% !important;
  padding: 9px 13px !important;
  border: 2px solid #c8dfc9 !important;
  border-radius: 8px !important;
  font-size: .88rem !important;
  background: #f4f6f4 !important;
  color: #2c3e50 !important;
  outline: none !important;
  transition: border-color .2s, box-shadow .2s !important;
}

#bbpress-forums fieldset input[type="text"]:focus,
#bbpress-forums fieldset textarea:focus {
  border-color: #2e7d32 !important;
  box-shadow: 0 0 0 3px rgba(46,125,50,.1) !important;
  background: #fff !important;
}

#bbpress-forums fieldset textarea { min-height: 140px !important; resize: vertical !important; line-height: 1.6 !important; }

#bbpress-forums .bbp-submit-wrapper input[type="submit"],
#bbpress-forums .bbp-submit-wrapper button[type="submit"] {
  background: #2e7d32 !important;
  border: none !important;
  border-radius: 8px !important;
  color: #fff !important;
  font-weight: 700 !important;
  font-size: .92rem !important;
  padding: 10px 22px !important;
  cursor: pointer !important;
  transition: all .18s !important;
}

#bbpress-forums .bbp-submit-wrapper input[type="submit"]:hover {
  background: #1b5e20 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 12px rgba(46,125,50,.28) !important;
}

/* ─── Notices ────────────────────────────────────────────── */
#bbpress-forums .bbp-template-notice {
  background: #e8f5e9 !important;
  border-left: 4px solid #2e7d32 !important;
  border-radius: 0 8px 8px 0 !important;
  padding: 10px 14px !important;
  margin-bottom: 14px !important;
  color: #1b5e20 !important;
  font-size: .88rem !important;
  border-top: none !important;
  border-right: none !important;
  border-bottom: none !important;
}

/* ─── Pagination ─────────────────────────────────────────── */
#bbpress-forums .bbp-pagination {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
  margin: 14px 0 !important;
}

#bbpress-forums .bbp-pagination-count { font-size: .82rem !important; color: #5a7a5c !important; }

#bbpress-forums .bbp-pagination-links { display: flex !important; gap: 3px !important; flex-wrap: wrap !important; }

#bbpress-forums .bbp-pagination-links a,
#bbpress-forums .bbp-pagination-links span.current,
#bbpress-forums .bbp-pagination-links span.dots {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: 32px !important;
  height: 32px !important;
  padding: 0 7px !important;
  border-radius: 6px !important;
  font-size: .85rem !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  transition: all .15s !important;
}

#bbpress-forums .bbp-pagination-links a {
  background: #fff !important;
  color: #2e7d32 !important;
  border: 1px solid #c8dfc9 !important;
}

#bbpress-forums .bbp-pagination-links a:hover { background: #2e7d32 !important; color: #fff !important; }

#bbpress-forums .bbp-pagination-links span.current {
  background: #2e7d32 !important;
  color: #fff !important;
  border: 1px solid #2e7d32 !important;
}

/* ─── Admin Links ────────────────────────────────────────── */
#bbpress-forums .bbp-admin-links {
  margin-top: 8px !important;
  display: flex !important;
  gap: 5px !important;
  flex-wrap: wrap !important;
}

#bbpress-forums .bbp-admin-links a {
  font-size: .72rem !important;
  color: #5a7a5c !important;
  border: 1px solid #c8dfc9 !important;
  padding: 2px 9px !important;
  border-radius: 20px !important;
  text-decoration: none !important;
  transition: all .15s !important;
}

#bbpress-forums .bbp-admin-links a:hover {
  color: #2e7d32 !important;
  border-color: #2e7d32 !important;
  background: #e8f5e9 !important;
}

/* ─── Sidebar-Widgets ausblenden ─────────────────────────── */
.widget_archive,
.widget_categories { display: none !important; }

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE  ≤ 700px
   ═══════════════════════════════════════════════════════════ */
@media (max-width: 700px) {

  /* Tabelle → Block */
  #bbpress-forums ul.bbp-forums,
  #bbpress-forums ul.bbp-topics {
    display: block !important;
  }

  #bbpress-forums ul.bbp-forums li.bbp-header,
  #bbpress-forums ul.bbp-topics li.bbp-header {
    display: none !important;
  }

  #bbpress-forums ul.bbp-forums li.bbp-forum,
  #bbpress-forums ul.bbp-topics li.bbp-topic {
    display: flex !important;
    flex-direction: column !important;
    padding: 12px 14px !important;
    border-bottom: 1px solid #e0ede1 !important;
  }

  #bbpress-forums ul.bbp-forums li.bbp-forum .bbp-forum-info,
  #bbpress-forums ul.bbp-forums li.bbp-forum p.bbp-forum-topic-count,
  #bbpress-forums ul.bbp-forums li.bbp-forum p.bbp-forum-reply-count,
  #bbpress-forums ul.bbp-forums li.bbp-forum p.bbp-forum-freshness,
  #bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-title,
  #bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-voice-count,
  #bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-reply-count,
  #bbpress-forums ul.bbp-topics li.bbp-topic .bbp-topic-freshness {
    display: block !important;
    width: auto !important;
    padding: 3px 0 !important;
    text-align: left !important;
  }

  #bbpress-forums ul.bbp-forums li.bbp-forum p.bbp-forum-topic-count,
  #bbpress-forums ul.bbp-forums li.bbp-forum p.bbp-forum-reply-count {
    display: inline-block !important;
    margin-right: 12px !important;
    font-size: .8rem !important;
    color: #5a7a5c !important;
    font-weight: normal !important;
  }

  #bbpress-forums ul.bbp-replies li.bbp-reply .bbp-reply-author {
    min-width: 80px !important;
    width: 80px !important;
  }
}
