/* =========================
   BBPRESS HUB ARCHIVE
   ========================= */

.bbp-hub-shell {
  --bbp-bg: #f5f7fb;
  --bbp-surface: #ffffff;
  --bbp-border: #e4e8ef;
  --bbp-text: #1f2937;
  --bbp-text-soft: #6b7280;
  --bbp-primary: #2563eb;
  --bbp-primary-dark: #1d4ed8;
  --bbp-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
  --bbp-radius-xl: 18px;
  --bbp-radius-lg: 14px;
  --bbp-radius-md: 10px;
  --bbp-gap: 24px;
  --bbp-sidebar-width: 340px;
    font-family: "Ubuntu", sans-serif;
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 24px;
  color: var(--bbp-text);
  box-sizing: border-box;
}


.bbp-hub-shell,
.bbp-hub-shell input,
.bbp-hub-shell button,
.bbp-hub-shell textarea,
.bbp-hub-shell select {
  font-family: "Ubuntu", sans-serif;
}
/* Toolbar */
.bbp-hub-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--bbp-border);
}

.bbp-hub-toolbar__left,
.bbp-hub-toolbar__right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.bbp-hub-sidebar-toggle,
.bbp-hub-new-topic-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 16px;
  border-radius: 12px;
  border: 1px solid var(--bbp-border);
  background: var(--bbp-surface);
  color: var(--bbp-text);
  font-size: 15px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.bbp-hub-sidebar-toggle:hover,
.bbp-hub-new-topic-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.bbp-hub-sidebar-toggle__icon {
  font-size: 16px;
  line-height: 1;
}

.bbp-hub-new-topic-btn {
  background: #111827;
  color: #fff;
  border-color: #111827;
}

.bbp-hub-new-topic-btn:hover {
  background: #000;
  color: #fff;
}

/* Layout */
.bbp-hub-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--bbp-sidebar-width);
  gap: var(--bbp-gap);
  align-items: start;
}

.bbp-hub-main,
.bbp-hub-sidebar {
  min-width: 0;
}

/* Sidebar collapsed */
.bbp-hub-shell.is-sidebar-collapsed .bbp-hub-layout {
  grid-template-columns: minmax(0, 1fr);
}

.bbp-hub-shell.is-sidebar-collapsed .bbp-hub-sidebar {
  display: none;
}

/* Main page */
.bbp-hub-page {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.bbp-hub-hero {
  padding: 28px;
  background: linear-gradient(135deg, #ffffff 0%, #f7f9fc 100%);
  border: 1px solid var(--bbp-border);
  border-radius: var(--bbp-radius-xl);
  box-shadow: var(--bbp-shadow);
}

.bbp-hub-title {
  margin: 0 0 8px;
  font-size: clamp(28px, 4vw, 38px);
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #111827;
}

.bbp-hub-subtitle {
  margin: 0;
  font-size: 16px;
  line-height: 1.6;
  color: var(--bbp-text-soft);
}

/* Searchbar top */
.bbp-hub-searchbar {
  padding: 18px 20px;
  background: var(--bbp-surface);
  border: 1px solid var(--bbp-border);
  border-radius: var(--bbp-radius-lg);
  box-shadow: var(--bbp-shadow);
}

/* Search form bbPress */
.bbp-hub-searchbar form,
.bbp-hub-widget--search form,
.bbp-search form {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}




/* Forums grid wrapper */
.bbp-hub-content {
  min-width: 0;
}

.bbp-hub-forum-grid,
.bbp-cards,
.bbp-cards--3 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

/* Fallback generico per gli item dei forum */
.bbp-hub-forum-grid > *,
.bbp-cards > *,
.bbp-cards--3 > *,
#bbpress-forums .bbp-forums-list li,
#bbpress-forums ul.forum-titles,
#bbpress-forums li.bbp-body > ul {
  min-width: 0;
}

/* Card styling generico */
.bbp-hub-forum-grid .bbp-forum-card,
.bbp-hub-forum-grid > article,
.bbp-hub-forum-grid > div,
.bbp-cards > article,
.bbp-cards > div {
  background: var(--bbp-surface);
  border: 1px solid var(--bbp-border);
  border-radius: var(--bbp-radius-xl);
  box-shadow: var(--bbp-shadow);
  overflow: hidden;
}

/* Sidebar */
.bbp-hub-sidebar {
  position: sticky;
  top: 24px;
}

.bbp-hub-sidebar__inner {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.bbp-hub-widget {
  background: var(--bbp-surface);
  border: 1px solid var(--bbp-border);
  border-radius: var(--bbp-radius-xl);
  box-shadow: var(--bbp-shadow);
  overflow: hidden;
}

.bbp-hub-widget__title {
  margin: 0;
  padding: 20px 20px 14px;
  font-size: 18px;
  font-weight: 800;
  color: #111827;
}

.bbp-hub-widget__body {
  padding: 0 20px 20px;
}

/* Widget inner bbPress */
.bbp-hub-widget .widget,
.bbp-hub-widget .bbp-template-notice,
.bbp-hub-widget .bbp-login-form,
.bbp-hub-widget .bbp-statistics {
  margin: 0;
  padding: 20px;
}

.bbp-hub-widget ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.bbp-hub-widget li {
  margin: 0;
  padding: 10px 0;
  border-bottom: 1px solid var(--bbp-border);
}

.bbp-hub-widget li:last-child {
  border-bottom: 0;
}

.bbp-hub-widget a {
  color: #1f3b8f;
  text-decoration: none;
}

.bbp-hub-widget a:hover {
  text-decoration: underline;
}

/* Statistics */
.bbp-hub-widget--stats .bbp-statistics ul {
  display: grid;
  gap: 10px;
}

.bbp-hub-widget--stats .bbp-statistics li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  font-size: 15px;
}

/* Empty */
.bbp-hub-empty,
.bbp-empty {
  padding: 22px;
  background: var(--bbp-surface);
  border: 1px dashed #cfd7e6;
  border-radius: var(--bbp-radius-lg);
  color: var(--bbp-text-soft);
}

/* Tabs shortcode area */
.bbp-hub-toolbar__left .bbp-tabs,
.bbp-hub-toolbar__left nav,
.bbp-hub-toolbar__left .tabs {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.bbp-hub-toolbar__left a,
.bbp-hub-toolbar__left button,
.bbp-hub-toolbar__left .tab {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 12px;
  text-decoration: none;
}

/* Responsive */
@media (max-width: 1100px) {
  .bbp-hub-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .bbp-hub-sidebar {
    position: static;
  }

  .bbp-hub-shell:not(.is-sidebar-collapsed) .bbp-hub-sidebar {
    display: block;
  }

  .bbp-hub-forum-grid,
  .bbp-cards,
  .bbp-cards--3 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767px) {
  .bbp-hub-shell {
    padding: 16px;
  }

  .bbp-hub-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .bbp-hub-toolbar__left,
  .bbp-hub-toolbar__right {
    width: 100%;
  }

  .bbp-hub-toolbar__right {
    justify-content: space-between;
  }

  .bbp-hub-hero {
    padding: 22px 18px;
  }

  .bbp-hub-title {
    font-size: 28px;
  }

  .bbp-hub-searchbar,
  .bbp-hub-widget__body,
  .bbp-hub-widget .widget,
  .bbp-hub-widget .bbp-template-notice,
  .bbp-hub-widget .bbp-login-form,
  .bbp-hub-widget .bbp-statistics {
    padding-left: 16px;
    padding-right: 16px;
  }

  .bbp-hub-widget__title {
    padding: 16px 16px 12px;
  }
}

.bbp-status-badge{
	position:relative;
	padding-left:22px !important;
}

/* Question */
.bbp-status-badge--question::before{
	content:"?";
	position:absolute;
	left:8px;
	font-weight:900;
}

/* Unsolved */
.bbp-status-badge--unsolved::before{
	content:"!";
	position:absolute;
	left:8px;
	font-weight:900;
}

/* Solved */
.bbp-status-badge--solved::before{
	content:"✓";
	position:absolute;
	left:8px;
	font-weight:900;
}

/* Rules */
.bbp-status-badge--rules::before{
	content:"!";
	position:absolute;
	left:8px;
	font-weight:900;
}

.bbp-status-badge{
	position:relative;
	padding-left:24px !important;
}

.bbp-status-badge::before{
	position:absolute;
	left:8px;
	top:50%;
	transform:translateY(-50%);
	font-family:"Font Awesome 5 Free";
	font-weight:900; /* necessario per solid */
	font-size:14px;
}

/* Question */
.bbp-status-badge--question::before{
	content:"\f059"; /* question-circle */
}

/* Unsolved */
.bbp-status-badge--unsolved::before{
	content:"\f071"; /* exclamation-triangle */
}

/* Solved */
.bbp-status-badge--solved::before{
	content:"\f00c"; /* check */
}

/* Rules */
.bbp-status-badge--rules::before{
	content:"\f06a"; /* exclamation-circle */
}

/* Announce */
.bbp-status-badge--announce::before{
	content:"\f0a1"; /* bullhorn */
}

.bbp-invision__header{
	display:flex;
	align-items:center;
	justify-content:space-between;
	flex-wrap:wrap;
}

.bbp-invision__actions{
	margin-left:auto;
	display:flex;
	gap:10px;
}

/* =========================
   FORUM TILES
   ========================= */

.bbp-hub-forum-grid,
.bbp-cards,
.bbp-cards--3 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.bbp-forum-tile {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  min-height: 132px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.bbp-forum-tile:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.12);
}

.bbp-forum-tile__accent {
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #fff;
  min-height: 100%;
}

.bbp-forum-tile__abbr {
  font-size: 34px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.bbp-forum-tile__content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  padding: 22px 24px;
  min-width: 0;
}

.bbp-forum-tile__header {
  min-width: 0;
}

.bbp-forum-tile__title {
  margin: 0;
  font-size: 20px;
  line-height: 1.25;
  font-weight: 800;
  color: #111827;
}

.bbp-forum-tile__title a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: inherit;
  text-decoration: none;
}

.bbp-forum-tile__title a:hover {
  color: #1d4ed8;
}

.bbp-forum-tile__lock {
  font-size: 15px;
  line-height: 1;
  opacity: 0.8;
}

.bbp-forum-tile__excerpt {
  color: #4b5563;
  font-size: 15px;
  line-height: 1.55;
}

.bbp-forum-tile__meta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  color: #6b7280;
  font-size: 13px;
  line-height: 1.4;
}

.bbp-forum-tile__stat {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  color: #374151;
}

.bbp-forum-tile__stat-label {
  font-weight: 500;
  color: #6b7280;
}

.bbp-forum-tile__freshness {
  min-width: 0;
}

.bbp-forum-tile__freshness a {
  color: #2563eb;
  text-decoration: none;
}

.bbp-forum-tile__freshness a:hover {
  text-decoration: underline;
}

/* Palette tile */
.bbp-forum-tile.is-accent-1 .bbp-forum-tile__accent {
  background: linear-gradient(135deg, #b58a95 0%, #a97d88 100%);
}

.bbp-forum-tile.is-accent-2 .bbp-forum-tile__accent {
  background: linear-gradient(135deg, #7c6bc8 0%, #9c7cff 100%);
}

.bbp-forum-tile.is-accent-3 .bbp-forum-tile__accent {
  background: linear-gradient(135deg, #ef5a31 0%, #ff4d2d 100%);
}

.bbp-forum-tile.is-accent-4 .bbp-forum-tile__accent {
  background: linear-gradient(135deg, #9046c4 0%, #b057ff 100%);
}

.bbp-forum-tile.is-accent-5 .bbp-forum-tile__accent {
  background: linear-gradient(135deg, #1290d8 0%, #0f7fd0 100%);
}

.bbp-forum-tile.is-accent-6 .bbp-forum-tile__accent {
  background: linear-gradient(135deg, #8d8d8a 0%, #9a9a97 100%);
}

.bbp-forum-tile.is-accent-7 .bbp-forum-tile__accent {
  background: linear-gradient(135deg, #45b4e8 0%, #58c0f1 100%);
}

.bbp-forum-tile.is-accent-8 .bbp-forum-tile__accent {
  background: linear-gradient(135deg, #7ed957 0%, #90ea67 100%);
}

/* Responsive */
@media (max-width: 1100px) {
  .bbp-hub-forum-grid,
  .bbp-cards,
  .bbp-cards--3 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .bbp-forum-tile {
    grid-template-columns: 82px minmax(0, 1fr);
    min-height: 112px;
  }

  .bbp-forum-tile__abbr {
    font-size: 26px;
  }

  .bbp-forum-tile__content {
    padding: 18px 18px;
  }

  .bbp-forum-tile__title {
    font-size: 18px;
  }

  .bbp-forum-tile__excerpt {
    font-size: 14px;
  }

  .bbp-forum-tile__meta {
    gap: 10px;
    font-size: 12px;
  }
}

/* =========================
   SECTIONS / SINGLE FORUM
   ========================= */

.bbp-hub-section {
  display: flex;
  flex-direction: column;

}

.bbp-hub-section__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.bbp-hub-section__title {
  margin: 0;
  font-size: 22px;
  line-height: 1.2;
  font-weight: 800;
  color: #111827;
}

.bbp-hub-section__actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Topic form hidden by default */
.bbp-topic-create .bbp-topic-form-wrap {
  display: none;
}

.bbp-topic-create.is-open .bbp-topic-form-wrap {
  display: block;
}

/* Topic list wrapper */
.bbp-topic-list-wrap {
  min-width: 0;
}

/* Bottoni generici */
.bbp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  background: #fff;
  color: #111827;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.bbp-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.bbp-btn--primary {
  background: #111827;
  border-color: #111827;
  color: #fff;
}

.bbp-btn--primary:hover {
  background: #000;
  color: #fff;
}

/* Topic form styling */
.bbp-topic-form-wrap form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.bbp-topic-form-wrap input[type="text"],
.bbp-topic-form-wrap input[type="email"],
.bbp-topic-form-wrap input[type="url"],
.bbp-topic-form-wrap select,
.bbp-topic-form-wrap textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #dbe1ea;
  border-radius: 12px;
  background: #fff;
  color: #111827;
  font-size: 15px;
  box-sizing: border-box;
}

.bbp-topic-form-wrap textarea {
  min-height: 180px;
  resize: vertical;
}

.bbp-topic-form-wrap input[type="submit"],
.bbp-topic-form-wrap button[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 0;
  border-radius: 12px;
  background: #2563eb;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

.bbp-topic-form-wrap input[type="submit"]:hover,
.bbp-topic-form-wrap button[type="submit"]:hover {
  background: #1d4ed8;
}

/* Standard bbPress topics table/list cleanup */
#bbpress-forums {
  margin: 0;
}

#bbpress-forums ul.bbp-topics,
#bbpress-forums ul.bbp-forums,
#bbpress-forums ul.bbp-replies {
  border: 0;
}

#bbpress-forums li.bbp-header,
#bbpress-forums li.bbp-footer {
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
}

#bbpress-forums li.bbp-body ul.topic,
#bbpress-forums li.bbp-body ul.forum {
  margin-bottom: 12px;
  padding: 16px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
}

#bbpress-forums li.bbp-body ul.topic:last-child,
#bbpress-forums li.bbp-body ul.forum:last-child {
  margin-bottom: 0;
}

/* Responsive */
@media (max-width: 767px) {
  .bbp-hub-section {
    padding: 18px;
  }

  .bbp-hub-section__title {
    font-size: 20px;
  }

  .bbp-hub-section__head {
    align-items: flex-start;
    flex-direction: column;
  }

  .bbp-hub-section__actions {
    width: 100%;
  }
}

/* =========================
   GUEST CTA / FEEDBACK
   ========================= */

.bbp-hub-widget--feedback {
  overflow: hidden;
}

.bbp-guest-cta {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 22px;
}

.bbp-guest-cta__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border-radius: 16px;
  background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
  font-size: 24px;
}

.bbp-guest-cta__content {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bbp-guest-cta__title {
  margin: 0;
  font-size: 20px;
  line-height: 1.2;
  font-weight: 800;
  color: #111827;
}

.bbp-guest-cta__desc {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: #6b7280;
}

.bbp-guest-cta__btn {
  margin-top: 4px;
  width: 100%;
}

/* =========================
   REPLY FORM
   ========================= */

.bbp-reply-create .bbp-reply-form-wrap {
display: none;
}

.bbp-reply-create.is-open .bbp-reply-form-wrap {
display: block;
}

.bbp-replies {
display: flex;
flex-direction: column;
gap: 16px;
}

/* =========================
   USER PAGE
   ========================= */

.bbp-user-hero__inner {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
}

.bbp-user-hero__avatar img {
  display: block;
  width: 96px;
  height: 96px;
  border-radius: 22px;
  object-fit: cover;
}

.bbp-user-hero__content {
  min-width: 0;
}

.bbp-user-tabs-wrap {
  padding: 14px 18px;
}

.bbp-user-tabs__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.bbp-user-tab {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  background: #fff;
  color: #374151;
  text-decoration: none;
  font-weight: 700;
  transition: all 0.2s ease;
}

.bbp-user-tab:hover {
  border-color: #cfd7e6;
  color: #111827;
  transform: translateY(-1px);
}

.bbp-user-tab.is-active {
  background: #111827;
  border-color: #111827;
  color: #fff;
}

.bbp-user-panel {
  min-width: 0;
}

#bbp-user-ajax-content {
  min-width: 0;
}

/* ripulisce output standard bbPress dentro il pannello */
#bbp-user-ajax-content .bbp-user-section,
#bbp-user-ajax-content .bbp-template-notice,
#bbp-user-ajax-content fieldset,
#bbp-user-ajax-content .bbp-form {
  max-width: 100%;
}

#bbp-user-ajax-content input[type="text"],
#bbp-user-ajax-content input[type="email"],
#bbp-user-ajax-content input[type="password"],
#bbp-user-ajax-content input[type="url"],
#bbp-user-ajax-content select,
#bbp-user-ajax-content textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #dbe1ea;
  border-radius: 12px;
  background: #fff;
  box-sizing: border-box;
}

#bbp-user-ajax-content textarea {
  min-height: 160px;
  resize: vertical;
}

#bbp-user-ajax-content input[type="submit"],
#bbp-user-ajax-content button[type="submit"] {
  min-height: 44px;
  padding: 0 16px;
  border: 0;
  border-radius: 12px;
  background: #2563eb;
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

#bbp-user-ajax-content input[type="submit"]:hover,
#bbp-user-ajax-content button[type="submit"]:hover {
  background: #1d4ed8;
}

@media (max-width: 767px) {
  .bbp-user-hero__inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .bbp-user-hero__avatar img {
    width: 78px;
    height: 78px;
    border-radius: 18px;
  }

  .bbp-user-tabs-wrap {
    padding: 14px;
  }
}

/* =========================
   RECENT TOPICS PAGE
   ========================= */

.bbp-hub-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 0 0 10px;
  font-size: 14px;
  line-height: 1.5;
  color: #6b7280;
}

.bbp-hub-breadcrumbs a {
  color: #2563eb;
  text-decoration: none;
}

.bbp-hub-breadcrumbs a:hover {
  text-decoration: underline;
}

.bbp-hub-breadcrumbs__sep {
  color: #9ca3af;
}

/* =========================
   STATISTICS WIDGET
   ========================= */

.bbp-stat-card {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.bbp-stat-card__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid #e5e7eb;
}

.bbp-stat-card__row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.bbp-stat-card__row:first-child {
  padding-top: 0;
}

.bbp-stat-card__row--stack {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.bbp-stat-card__label {
  font-size: 14px;
  line-height: 1.5;
  color: #6b7280;
}

.bbp-stat-card__value {
  text-align: right;
  font-size: 14px;
  line-height: 1.5;
  font-weight: 800;
  color: #111827;
}

.bbp-stat-card__link,
.bbp-stat-card__userlink {
  color: #2563eb;
  text-decoration: none;
}

.bbp-stat-card__link:hover,
.bbp-stat-card__userlink:hover {
  text-decoration: underline;
}

.bbp-stat-card__online-list {
  width: 100%;
  font-size: 14px;
  line-height: 1.6;
  color: #374151;
}

/* =========================
   REPLIES
   ========================= */

.bbp-replies {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.bbp-reply-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

.bbp-reply-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px 0;
}

.bbp-reply-card__who {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex-wrap: wrap;
}

.bbp-reply-card__author {
  min-width: 0;
}

.bbp-reply-card__role {
  display: inline-flex;
  align-items: center;
}

.bbp-role-badge {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1;
  font-weight: 800;
}

.bbp-role-badge--admin {
  background: #fee2e2;
  color: #991b1b;
}

.bbp-role-badge--mod {
  background: #ede9fe;
  color: #5b21b6;
}

.bbp-reply-card__meta {
  flex: 0 0 auto;
}

.bbp-reply-card__date {
  font-size: 13px;
  line-height: 1.4;
  color: #6b7280;
  text-decoration: none;
  white-space: nowrap;
}

.bbp-reply-card__date:hover {
  color: #2563eb;
  text-decoration: underline;
}

.bbp-reply-card__body {
  padding: 16px 22px 0;
}

.bbp-reply-card__content {
  font-size: 15px;
  line-height: 1.75;
  color: #1f2937;
}

.bbp-reply-card__content > :first-child {
  margin-top: 0;
}

.bbp-reply-card__content > :last-child {
  margin-bottom: 0;
}

.bbp-reply-card__content p,
.bbp-reply-card__content ul,
.bbp-reply-card__content ol,
.bbp-reply-card__content blockquote,
.bbp-reply-card__content pre {
  margin-bottom: 1em;
}

.bbp-reply-card__content blockquote {
  margin-left: 0;
  padding: 12px 16px;
  border-left: 4px solid #dbeafe;
  background: #f8fbff;
  border-radius: 10px;
}

.bbp-reply-card__content pre {
  overflow: auto;
  padding: 14px;
  border-radius: 12px;
  background: #111827;
  color: #f9fafb;
}

.bbp-reply-card__content code {
  font-size: 0.95em;
}

.bbp-reply-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  padding: 18px 22px 20px;
}

.bbp-reply-card__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.bbp-reply-card__actions a {
  color: #6b7280;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
}

.bbp-reply-card__actions a:hover {
  color: #111827;
  text-decoration: underline;
}

.bbp-btn--ghost {
  background: #fff;
  border: 1px solid #d1d5db;
  color: #111827;
}

.bbp-btn--ghost:hover {
  background: #f9fafb;
}

/* Migliora eventuale markup di userpop */
.bbp-reply-card .bbp-author-link,
.bbp-reply-card .bbp-userpop,
.bbp-reply-card .bbp-author-name {
  max-width: 100%;
}

/* Responsive */
@media (max-width: 767px) {
  .bbp-reply-card__head,
  .bbp-reply-card__body,
  .bbp-reply-card__foot {
    padding-left: 16px;
    padding-right: 16px;
  }

  .bbp-reply-card__head {
    flex-direction: column;
    align-items: flex-start;
  }

  .bbp-reply-card__date {
    white-space: normal;
  }

  .bbp-reply-card__foot {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* =========================
   TOPIC STREAM
   ========================= */

.bbp-topic-stream {
  flex-direction: column;
  gap: 18px;
}

.bbp-topic-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

.bbp-topic-card__main {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 22px;
}

.bbp-topic-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.bbp-topic-card__titlewrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
  flex: 1 1 auto;
}

.bbp-topic-card__title {
  margin: 0;
  font-size: 20px;
  line-height: 1.3;
  font-weight: 800;
  color: #111827;
}

.bbp-topic-card__title a {
  color: inherit;
  text-decoration: none;
}

.bbp-topic-card__title a:hover {
  color: #2563eb;
}

.bbp-topic-card__badges {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.bbp-topic-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1;
  font-weight: 800;
}

.bbp-topic-badge--super {
  background: #dbeafe;
  color: #1d4ed8;
}

.bbp-topic-badge--sticky {
  background: #ede9fe;
  color: #6d28d9;
}

.bbp-topic-badge--closed {
  background: #fee2e2;
  color: #b91c1c;
}

.bbp-topic-card__stats {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.bbp-topic-card__stat {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  min-height: 58px;
  padding: 6px 10px;
  border-radius: 14px;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  text-align: center;
}

.bbp-topic-card__stat strong {
  font-size: 18px;
  line-height: 1.1;
  color: #111827;
}

.bbp-topic-card__stat span {
  margin-top: 4px;
  font-size: 12px;
  line-height: 1;
  color: #6b7280;
}

.bbp-topic-card__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.bbp-topic-card__meta-left {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  min-width: 0;
  color: #6b7280;
  font-size: 14px;
  line-height: 1.5;
}

.bbp-topic-card__author a,
.bbp-topic-card__forum,
.bbp-topic-card__freshness a {
  color: #2563eb;
  text-decoration: none;
}

.bbp-topic-card__author a:hover,
.bbp-topic-card__forum:hover,
.bbp-topic-card__freshness a:hover {
  text-decoration: underline;
}

.bbp-topic-card__sep {
  color: #9ca3af;
}

.bbp-topic-card__freshness {
  font-size: 14px;
  line-height: 1.5;
  color: #6b7280;
}

.bbp-topic-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.bbp-topic-card__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.bbp-topic-card__actions a {
  color: #6b7280;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
}

.bbp-topic-card__actions a:hover {
  color: #111827;
  text-decoration: underline;
}

.bbp-pager {
  margin-top: 22px;
}

/* Responsive */
@media (max-width: 767px) {
  .bbp-topic-card__main {
    padding: 18px;
  }

  .bbp-topic-card__head {
    flex-direction: column;
    align-items: flex-start;
  }

  .bbp-topic-card__stats {
    width: 100%;
  }

  .bbp-topic-card__meta {
    flex-direction: column;
    align-items: flex-start;
  }

  .bbp-topic-card__foot {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* =========================
   USER DETAILS
   ========================= */

.bbp-user-details {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.bbp-user-details__aside {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.bbp-user-details__main {
  min-width: 0;
}

.bbp-user-card__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 16px;
}

.bbp-user-card__avatar img {
  display: block;
  width: 120px;
  height: 120px;
  border-radius: 24px;
  object-fit: cover;
}

.bbp-user-card__meta {
  min-width: 0;
}

.bbp-user-card__name {
  margin: 0;
  font-size: 22px;
  line-height: 1.2;
  font-weight: 800;
  color: #111827;
}

.bbp-user-card__name a {
  color: inherit;
  text-decoration: none;
}

.bbp-user-card__name a:hover {
  color: #2563eb;
}

.bbp-user-card__handle {
  margin-top: 6px;
  font-size: 14px;
  line-height: 1.5;
  color: #6b7280;
}

.bbp-user-side-nav {
  padding: 0;
}

.bbp-user-side-nav__list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.bbp-user-side-nav__list li {
  margin: 0;
  padding: 0;
  border-bottom: 1px solid #e5e7eb;
}

.bbp-user-side-nav__list li:last-child {
  border-bottom: 0;
}

.bbp-user-side-nav__list a {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 0 4px;
  color: #374151;
  text-decoration: none;
  font-weight: 700;
}

.bbp-user-side-nav__list a:hover {
  color: #111827;
}

.bbp-user-side-nav__list li.is-active a {
  color: #2563eb;
}

@media (max-width: 900px) {
  .bbp-user-details {
    grid-template-columns: 1fr;
  }
}

/* Nasconde il toggle sidebar su tablet e mobile,
   senza toccare la sidebar */
@media (max-width: 1100px) {
  .bbp-hub-sidebar-toggle,
  .js-bbp-sidebar-toggle {
    display: none !important;
  }
}

/* =========================
   USER POP
   ========================= */

.bbp-userpop {
  position: relative;
  display: inline-flex;
}

.bbp-userpop__trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #2563eb;
  text-decoration: none;
}

.bbp-userpop__trigger:hover {
  text-decoration: underline;
}

.bbp-userpop__card {
  position: absolute;
  left: 0;
  top: calc(100% + 10px);
  z-index: 50;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 240px;
  max-width: 280px;
  padding: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.14);
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s ease;
}

.bbp-userpop:hover .bbp-userpop__card,
.bbp-userpop:focus-within .bbp-userpop__card {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.bbp-userpop__row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.bbp-userpop__avatar img {
  display: block;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  object-fit: cover;
}

.bbp-userpop__meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.bbp-userpop__name {
  font-size: 14px;
  font-weight: 800;
  color: #111827;
}

.bbp-userpop__nick {
  font-size: 13px;
  color: #6b7280;
}

.bbp-userpop__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.bbp-userpop__badge {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  background: #f3f4f6;
  color: #374151;
  font-size: 12px;
  font-weight: 700;
}

.bbp-userpop__badge--accent {
  background: #dbeafe;
  color: #1d4ed8;
}

.bbp-userpop__badge--danger {
  background: #fee2e2;
  color: #b91c1c;
}

.bbp-userpop__stats {
  display: flex;
  gap: 10px;
}

.bbp-userpop__stat {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  min-width: 74px;
  min-height: 52px;
  padding: 8px 10px;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  background: #f8fafc;
  text-align: center;
  font-size: 12px;
  color: #6b7280;
}

.bbp-userpop__stat strong {
  font-size: 16px;
  line-height: 1.1;
  color: #111827;
}

/* =========================
   BBPRESS ANNOUNCEMENTS
   ========================= */

.bbpa-wrap {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-bottom: 20px;
}

/* card base */

.bbpa-alert {
  position: relative;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

/* header */

.bbpa-alert-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px 0;
}

.bbpa-alert-title {
  font-size: 18px;
  line-height: 1.25;
  font-weight: 800;
  color: #111827;
}

/* close */

.bbpa-close {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid #d1d5db;
  background: #ffffff;
  color: #6b7280;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  transition: all .2s ease;
}

.bbpa-close:hover {
  background: #f9fafb;
  color: #111827;
}

/* body */

.bbpa-alert-body {
  padding: 14px 20px 20px;
  font-size: 15px;
  line-height: 1.7;
  color: #374151;
}

.bbpa-alert-body > :first-child {
  margin-top: 0;
}

.bbpa-alert-body > :last-child {
  margin-bottom: 0;
}

.bbpa-alert-body a {
  color: #2563eb;
  text-decoration: none;
}

.bbpa-alert-body a:hover {
  text-decoration: underline;
}

/* =========================
   LEVELS
   ========================= */

/* info */

.bbpa-alert-info {
  border-left: 5px solid #2563eb;
}

.bbpa-alert-info .bbpa-alert-head {
  background: linear-gradient(180deg,#eff6ff 0%,rgba(239,246,255,0) 100%);
}

/* warning */

.bbpa-alert-warning {
  border-left: 5px solid #f59e0b;
}

.bbpa-alert-warning .bbpa-alert-head {
  background: linear-gradient(180deg,#fffbeb 0%,rgba(255,251,235,0) 100%);
}

/* danger */

.bbpa-alert-danger {
  border-left: 5px solid #ef4444;
}

.bbpa-alert-danger .bbpa-alert-head {
  background: linear-gradient(180deg,#fef2f2 0%,rgba(254,242,242,0) 100%);
}

/* =========================
   SIDEBAR VERSION
   ========================= */

.bbp-hub-sidebar .bbpa-alert {
  border-radius: 16px;
  box-shadow: 0 6px 18px rgba(15,23,42,.06);
}

.bbp-hub-sidebar .bbpa-alert-title {
  font-size: 16px;
}

/* =========================
   MOBILE
   ========================= */

@media (max-width: 767px) {

  .bbpa-alert-head,
  .bbpa-alert-body {
    padding-left: 16px;
    padding-right: 16px;
  }

  .bbpa-alert-title {
    font-size: 16px;
  }

}

.bbp-forum-tile__subforums {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 8px;
}

.bbp-forum-tile__subforums-label {
  font-size: 12px;
  line-height: 1.4;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #6b7280;
}

.bbp-forum-tile__subforums-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.bbp-forum-tile__subforum {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  background: #f8fafc;
  color: #374151;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.bbp-forum-tile__subforum:hover {
  background: #eef2ff;
  border-color: #c7d2fe;
  color: #1d4ed8;
}

.bbp-forum-tile__subforum--more {
  background: #111827;
  border-color: #111827;
  color: #fff;
}

.bbp-forum-tile__subforum--more:hover {
  background: #000;
  border-color: #000;
  color: #fff;
}

/* =========================
   SEARCH PAGE
   ========================= */

.bbp-search-page {
  min-width: 0;
}

.bbp-search-page__form {
  margin-bottom: 18px;
}

.bbp-search-page__results {
  min-width: 0;
}

.bbp-search-page .bbp-pagination {
  margin: 0 0 16px;
}

.bbp-search-page .bbp-pagination + ul,
.bbp-search-page .bbp-pagination + div {
  margin-top: 0;
}

/* Search form dentro section */
.bbp-search-page form,
.bbp-search-page fieldset {
  margin: 0;
}

.bbp-search-page .bbp-search-form,
.bbp-search-page form {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.bbp-search-page input[type="text"],
.bbp-search-page input[type="search"] {
  flex: 1 1 260px;
  min-width: 0;
  height: 46px;
  padding: 0 14px;
  border: 1px solid #dbe1ea;
  border-radius: 12px;
  background: #fff;
  color: #111827;
  font-size: 15px;
  box-sizing: border-box;
}

.bbp-search-page form input[type="submit"],
.bbp-search-page form button[type="submit"] {
  height: 46px;
  padding: 0 18px;
  border: 0;
  border-radius: 12px;
  background: #2563eb;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

.bbp-search-page form input[type="submit"]:hover,
.bbp-search-page form button[type="submit"]:hover {
  background: #1d4ed8;
}


/* =========================
   SEARCH CARDS
   ========================= */

.bbp-search-page .bbp-search-results,
.bbp-search-page .bbp-search-results-wrap,
.bbp-search-page .bbp-topic-stream {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.bbp-search-card {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.bbp-search-card__accent {
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #fff;
  min-height: 100%;
}

.bbp-search-card__abbr {
  font-size: 30px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.bbp-search-card__content {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 20px 22px;
  min-width: 0;
}

.bbp-search-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.bbp-search-card__titlewrap {
  min-width: 0;
  flex: 1 1 auto;
}

.bbp-search-card__eyebrow {
  margin-bottom: 6px;
  font-size: 12px;
  line-height: 1.4;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #6b7280;
}

.bbp-search-card__title {
  margin: 0;
  font-size: 22px;
  line-height: 1.25;
  font-weight: 800;
  color: #111827;
}

.bbp-search-card__title a {
  color: inherit;
  text-decoration: none;
}

.bbp-search-card__title a:hover {
  color: #2563eb;
}

.bbp-search-card__lock {
  margin-right: 6px;
  font-size: 15px;
  opacity: .8;
}

.bbp-search-card__stats {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.bbp-search-card__stat {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  min-height: 56px;
  padding: 6px 10px;
  border-radius: 14px;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  text-align: center;
}

.bbp-search-card__stat strong {
  font-size: 17px;
  line-height: 1.1;
  color: #111827;
}

.bbp-search-card__stat span {
  margin-top: 4px;
  font-size: 12px;
  line-height: 1;
  color: #6b7280;
}

.bbp-search-card__excerpt {
  font-size: 15px;
  line-height: 1.65;
  color: #4b5563;
}

.bbp-search-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.bbp-search-card__freshness {
  font-size: 14px;
  line-height: 1.5;
  color: #6b7280;
}

.bbp-search-card__freshness a {
  color: #2563eb;
  text-decoration: none;
}

.bbp-search-card__freshness a:hover {
  text-decoration: underline;
}

/* Palette */
.bbp-search-card.is-accent-1 .bbp-search-card__accent {
  background: linear-gradient(135deg, #b58a95 0%, #a97d88 100%);
}
.bbp-search-card.is-accent-2 .bbp-search-card__accent {
  background: linear-gradient(135deg, #7c6bc8 0%, #9c7cff 100%);
}
.bbp-search-card.is-accent-3 .bbp-search-card__accent {
  background: linear-gradient(135deg, #ef5a31 0%, #ff4d2d 100%);
}
.bbp-search-card.is-accent-4 .bbp-search-card__accent {
  background: linear-gradient(135deg, #9046c4 0%, #b057ff 100%);
}
.bbp-search-card.is-accent-5 .bbp-search-card__accent {
  background: linear-gradient(135deg, #1290d8 0%, #0f7fd0 100%);
}
.bbp-search-card.is-accent-6 .bbp-search-card__accent {
  background: linear-gradient(135deg, #8d8d8a 0%, #9a9a97 100%);
}
.bbp-search-card.is-accent-7 .bbp-search-card__accent {
  background: linear-gradient(135deg, #45b4e8 0%, #58c0f1 100%);
}
.bbp-search-card.is-accent-8 .bbp-search-card__accent {
  background: linear-gradient(135deg, #7ed957 0%, #90ea67 100%);
}

@media (max-width: 767px) {
  .bbp-search-card {
    grid-template-columns: 74px minmax(0, 1fr);
  }

  .bbp-search-card__abbr {
    font-size: 24px;
  }

  .bbp-search-card__content {
    padding: 16px;
  }

  .bbp-search-card__head {
    flex-direction: column;
    align-items: flex-start;
  }

  .bbp-search-card__title {
    font-size: 19px;
  }

  .bbp-search-card__foot {
    flex-direction: column;
    align-items: flex-start;
  }
}

.bbp-search-card--reply .bbp-search-card__accent--reply {
  background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
}

.bbp-search-card--reply .bbp-search-card__eyebrow a,
.bbp-search-card--reply .bbp-search-card__forum {
  color: #2563eb;
  text-decoration: none;
}

.bbp-search-card--reply .bbp-search-card__eyebrow a:hover,
.bbp-search-card--reply .bbp-search-card__forum:hover {
  text-decoration: underline;
}

/* =========================
   REPLY FORM CARD
   ========================= */

.bbp-reply-create-card {
  margin-top: 18px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

.bbp-reply-create-card__form {
  margin: 0;
}

.bbp-reply-create-card__fieldset {
  margin: 0;
  border: 0;
  padding: 0;
  min-width: 0;
}

.bbp-reply-create-card__legend {
  display: block;
  width: 100%;
  margin: 0;
  padding: 20px 22px;
  border-bottom: 1px solid #e5e7eb;
  background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%);
  font-size: 20px;
  line-height: 1.3;
  font-weight: 800;
  color: #111827;
  box-sizing: border-box;
}

.bbp-reply-create-card__body {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 22px;
}

.bbp-reply-create-card__editor {
  min-width: 0;
}

.bbp-reply-create-card__meta {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* righe form */
.bbp-form-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bbp-form-row__label {
  font-size: 14px;
  line-height: 1.4;
  font-weight: 700;
  color: #374151;
}



/* checkbox row */
.bbp-check-row {
  display: inline-flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  line-height: 1.5;
  color: #374151;
  cursor: pointer;
}

.bbp-check-row input[type="checkbox"] {
  margin-top: 2px;
  flex: 0 0 auto;
}

/* edit log box */
.bbp-reply-edit-log {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 16px;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  background: #f8fafc;
}

/* footer actions */
.bbp-reply-create-card__footer {
  padding-top: 4px;
}

.bbp-actions--reply {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* cancel link */
.bbp-actions--reply a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  background: #fff;
  color: #374151;
  text-decoration: none;
  font-weight: 700;
  transition: all 0.2s ease;
}

.bbp-actions--reply a:hover {
  background: #f9fafb;
  color: #111827;
  transform: translateY(-1px);
}

/* editor standard bbPress / TinyMCE / Quicktags */
.bbp-reply-create-card .wp-editor-wrap,
.bbp-reply-create-card .quicktags-toolbar,
.bbp-reply-create-card .mce-toolbar-grp,
.bbp-reply-create-card .wp-editor-container {
  border-color: #dbe1ea;
}

.bbp-reply-create-card .wp-editor-container,
.bbp-reply-create-card textarea {
  border-radius: 12px;
  overflow: hidden;
}

/* allowed tags */
.bbp-reply-create-card .bbp-the-content-wrapper + p,
.bbp-reply-create-card .bbp-form-allowed-tags,
.bbp-reply-create-card p.bbp-topic-tags {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: #6b7280;
}

/* notice dentro il form */
.bbp-reply-create-card .bbp-template-notice {
  margin: 0 22px;
  border-radius: 14px;
}

/* responsive */
@media (max-width: 767px) {
  .bbp-reply-create-card__legend {
    padding: 16px;
    font-size: 18px;
  }

  .bbp-reply-create-card__body {
    padding: 16px;
  }

  .bbp-actions--reply {
    flex-direction: column;
    align-items: stretch;
  }

  .bbp-actions--reply a,
  .bbp-actions--reply .bbp-btn {
    width: 100%;
    justify-content: center;
  }

  .bbp-reply-create-card .bbp-template-notice {
    margin-left: 16px;
    margin-right: 16px;
  }
}

/* =========================
   TOPIC FORM CARD
   ========================= */

.bbp-topic-create-card {
  margin-top: 18px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

.bbp-topic-create-card__form {
  margin: 0;
}

.bbp-topic-create-card__fieldset {
  margin: 0;
  border: 0;
  padding: 0;
  min-width: 0;
}

.bbp-topic-create-card__legend {
  display: block;
  width: 100%;
  margin: 0;
  padding: 20px 22px;
  border-bottom: 1px solid #e5e7eb;
  background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%);
  font-size: 20px;
  line-height: 1.3;
  font-weight: 800;
  color: #111827;
  box-sizing: border-box;
}

.bbp-topic-create-card__body {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 22px;
}

.bbp-topic-create-card__editor {
  min-width: 0;
}

.bbp-topic-create-card__meta {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.bbp-topic-create-card__footer {
  padding-top: 4px;
}

.bbp-actions--topic {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* editor */
.bbp-topic-create-card .wp-editor-wrap,
.bbp-topic-create-card .quicktags-toolbar,
.bbp-topic-create-card .mce-toolbar-grp,
.bbp-topic-create-card .wp-editor-container {
  border-color: #dbe1ea;
}

.bbp-topic-create-card .wp-editor-container,
.bbp-topic-create-card textarea {
  border-radius: 12px;
  overflow: hidden;
}

/* select e dropdown bbPress dentro wrappers */
.bbp-topic-create-card select,
.bbp-topic-create-card .bbp-form-row__control select {
  width: 100%;
  min-height: 46px;
  padding: 12px 14px;
  border: 1px solid #dbe1ea;
  border-radius: 12px;
  background: #fff;
  color: #111827;
  font-size: 15px;
  box-sizing: border-box;
}

/* allowed tags / help text */
.bbp-topic-create-card .bbp-the-content-wrapper + p,
.bbp-topic-create-card .bbp-form-allowed-tags {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: #6b7280;
}

/* edit log box */
.bbp-topic-edit-log {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 16px;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  background: #f8fafc;
}

/* migliora eventuali panel vecchi residui */
.bbp-topic-create-card .bbp-iv-panel {
  margin: 0;
  border: 0;
  box-shadow: none;
  background: transparent;
}

.bbp-topic-create-card .bbp-template-notice {
  margin: 0;
  border-radius: 14px;
}

/* mobile */
@media (max-width: 767px) {
  .bbp-topic-create-card__legend {
    padding: 16px;
    font-size: 18px;
  }

  .bbp-topic-create-card__body {
    padding: 16px;
  }

  .bbp-actions--topic {
    flex-direction: column;
    align-items: stretch;
  }

  .bbp-actions--topic .bbp-btn {
    width: 100%;
    justify-content: center;
  }
}

#bbpress-forums fieldset.bbp-form {
  clear: left;
  border: 0 !important;
  padding: 10px 20px;
  margin-bottom: 10px;
}

/* =========================
   BBP HUB PAGINATION
   ========================= */

.bbp-hub-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 4px 0;
}

.bbp-hub-pagination--top {
  margin-bottom: 16px;
}

.bbp-hub-pagination--bottom {
  margin-top: 16px;
}

/* Tutti i link e span generati da paginate_links() */
.bbp-hub-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 10px;
  border: 1px solid var(--bbp-border, #e4e8ef);
  border-radius: 12px;
  background: #ffffff;
  color: #374151;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04);
}

.bbp-hub-pagination .page-numbers:hover {
  border-color: #c7d2fe;
  background: #eef2ff;
  color: #1d4ed8;
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.08);
}

/* Pagina corrente */
.bbp-hub-pagination .page-numbers.current {
  background: #111827;
  border-color: #111827;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(17, 24, 39, 0.22);
  cursor: default;
  transform: none;
}

/* Puntini … */
.bbp-hub-pagination .page-numbers.dots {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
  color: #9ca3af;
  cursor: default;
  min-width: 28px;
  padding: 0;
  letter-spacing: .05em;
}

.bbp-hub-pagination .page-numbers.dots:hover {
  background: transparent;
  border-color: transparent;
  color: #9ca3af;
  transform: none;
  box-shadow: none;
}

/* Prev / Next — frecce più larghe */
.bbp-hub-pagination .page-numbers.prev,
.bbp-hub-pagination .page-numbers.next {
  padding: 0 14px;
  color: #2563eb;
  border-color: #dbeafe;
  background: #eff6ff;
}

.bbp-hub-pagination .page-numbers.prev:hover,
.bbp-hub-pagination .page-numbers.next:hover {
  background: #dbeafe;
  border-color: #93c5fd;
  color: #1d4ed8;
}

/* Responsive */
@media (max-width: 480px) {
  .bbp-hub-pagination {
    gap: 4px;
  }

  .bbp-hub-pagination .page-numbers {
    min-width: 36px;
    height: 36px;
    font-size: 13px;
    border-radius: 10px;
  }

  .bbp-hub-pagination .page-numbers.prev,
  .bbp-hub-pagination .page-numbers.next {
    padding: 0 10px;
  }
}

/* =========================
   BBP PAGINATION COUNT
   — banner stile topic-info
   ========================= */

.bbp-pagination-count {
  display: grid;
  min-height: 64px;
  grid-template-columns: 880px minmax(0, 1fr);
  background: linear-gradient(135deg, #f0f5ff 0%, #ffffff 60%) !important;
  border: 1px solid #dbeafe;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.08);
}

/* Accent block sinistro */
.bbp-pagination-count__accent {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: #ffffff;
  font-size: 22px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
  flex-shrink: 0;
}

/* Corpo testo */
.bbp-pagination-count__body {
  display: flex;
  align-items: center;
  padding: 14px 20px;
  font-size: 14px;
  line-height: 1.6;
  color: #374151;
  min-width: 0;
}

.bbp-pagination-count__body a {
  color: #2563eb;
  font-weight: 700;
  text-decoration: none;
}

.bbp-pagination-count__body a:hover {
  text-decoration: underline;
}

/* Nome utente in evidenza */
.bbp-pagination-count__body .bbp-author-name,
.bbp-pagination-count__body .bbp-user-name,
.bbp-pagination-count__body strong {
  color: #dc2626;
  font-weight: 700;
}

/* Responsive */
@media (max-width: 480px) {
  .bbp-pagination-count {
    grid-template-columns: 280px minmax(0, 1fr);
    min-height: 56px;
    border-radius: 14px;
  }

  .bbp-pagination-count__accent {
    font-size: 18px;
  }

  .bbp-pagination-count__body {
    padding: 12px 14px;
    font-size: 13px;
  }
}

.bbp-reply-create-card__editor textarea,
.bbp-the-content-wrapper textarea,
#bbp_reply_content {
	min-height: 260px;
	max-height: 520px;
	overflow-y: auto;
	resize: vertical;
	box-sizing: border-box;
	width: 100%;
}

.bbp-topic-create-card__editor textarea,
.bbp-reply-create-card__editor textarea,
#bbp_topic_content,
#bbp_reply_content {
	width: 100%;
	min-height: 260px;
	height: 320px;
	max-height: 520px;
	overflow-y: auto;
	resize: vertical;
	box-sizing: border-box;
}

.bbp-topic-create-card__editor,
.bbp-reply-create-card__editor,
.bbp-topic-create-card__body,
.bbp-reply-create-card__body,
.bbp-topic-create-card__fieldset,
.bbp-reply-create-card__fieldset {
	min-height: 0;
	overflow: visible;
}
