/* ═══════════════════════════════════════════════════════
   POND THEME — Geographic Forum Overrides
   Retargets cdk_geographic_forums module classes
   to use pond design tokens.
   ═══════════════════════════════════════════════════════ */

/* ── Hide redundant page title block on forum pages ── */
/* Each template has its own h1; the Drupal block just shows "Forums" */
#block-pond-theme-page-title:has(+ #block-pond-theme-content .cdk-geographic-forum-overview),
#block-pond-theme-page-title:has(+ #block-pond-theme-content .forum-topic) {
  display: none;
}

/* ── Forum Overview (cdk-geographic-forum-overview) ── */

.cdk-geographic-forum-overview {
  max-width: none;
  padding: 0;
  font-family: var(--font-body);
}

.cdk-forum-cascade .forum-header {
  margin-bottom: var(--space-xl);
}

.cdk-forum-cascade .forum-header h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--pond-ink);
}

.cdk-forum-cascade .breadcrumb a {
  color: var(--pond-green-mid);
}

.cdk-forum-cascade .breadcrumb a:hover {
  color: var(--pond-green);
}

/* Forum sections */
.forum-section {
  border-color: var(--pond-cloud);
  border-radius: var(--radius-lg);
  background: var(--pond-white);
  box-shadow: var(--shadow-sm);
}

.forum-section--primary {
  border-color: var(--pond-green-mid);
  box-shadow: var(--shadow-md);
}

.forum-section--primary::before {
  background: linear-gradient(90deg, var(--pond-green), var(--pond-green-mid));
}

.forum-section--primary .forum-section-title {
  color: var(--pond-green);
  background: var(--pond-frost);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.125rem;
  padding: var(--space-lg) var(--space-xl);
  border-bottom-color: var(--pond-cloud);
}

.forum-section--secondary::before {
  background: linear-gradient(90deg, var(--pond-slate), var(--pond-mist));
}

.forum-section--secondary .forum-section-toggle,
.forum-section--tertiary .forum-section-toggle,
.forum-section--quaternary .forum-section-toggle {
  background: var(--pond-frost);
}

.forum-count {
  color: var(--pond-mist);
}

/* Forum table */
.forum-table {
  font-family: var(--font-body);
}

.forum-table thead {
  background: var(--pond-frost);
}

.forum-table th {
  color: var(--pond-slate);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.8125rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: var(--space-md) var(--space-lg);
  border-bottom-color: var(--pond-cloud);
}

.forum-table td {
  padding: var(--space-lg);
  border-bottom-color: var(--pond-frost);
}

.forum-row:hover {
  background: var(--pond-frost);
}

.forum-name {
  font-weight: 500;
}

.forum-name a {
  color: var(--pond-ink);
  transition: color var(--transition-fast);
}

.forum-name a:hover {
  color: var(--pond-green-mid);
}

.forum-description {
  color: var(--pond-slate);
}

.forum-stat,
.forum-last {
  color: var(--pond-slate);
  font-size: 0.8125rem;
}

.last-post-date {
  display: block;
  font-size: 0.8125rem;
  color: var(--pond-slate);
}

.last-post-user {
  display: block;
  font-size: 0.75rem;
  color: var(--pond-mist);
}


/* ── Topic Detail Page (cdk-geographic-forum-topic) ── */
/* Override inline <style> from the module template    */

.forum-topic {
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  font-family: var(--font-body) !important;
}

.forum-topic .forum-header {
  margin-bottom: var(--space-xl) !important;
  border-bottom: 2px solid var(--pond-cloud) !important;
  padding-bottom: var(--space-lg) !important;
}

.forum-topic .forum-header h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--pond-ink);
}

.forum-topic .forum-context {
  color: var(--pond-slate) !important;
  font-size: 0.875rem !important;
}

.forum-topic .forum-description {
  background: var(--pond-frost) !important;
  border-left: 4px solid var(--pond-green-mid) !important;
  border-radius: var(--radius-md) !important;
  color: var(--pond-charcoal) !important;
}

/* Consensus link */
.consensus-link {
  background: linear-gradient(135deg, var(--pond-green) 0%, var(--pond-green-mid) 100%) !important;
  border-radius: var(--radius-lg) !important;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast) !important;
}

.consensus-link:hover {
  box-shadow: var(--shadow-lg) !important;
}

/* Child topics list */
.child-topics {
  background: var(--pond-frost) !important;
  border-radius: var(--radius-lg) !important;
  padding: var(--space-xl) !important;
  margin-bottom: var(--space-xl) !important;
}

.child-topics h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.125rem;
  color: var(--pond-ink);
  margin-bottom: var(--space-lg);
}

.topic-list li {
  background: var(--pond-white) !important;
  border-radius: var(--radius-md) !important;
  border-left: 4px solid var(--pond-green-mid) !important;
  padding: var(--space-md) var(--space-lg) !important;
  margin: var(--space-sm) 0 !important;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.topic-list li:hover {
  transform: translateX(2px);
  box-shadow: var(--shadow-sm);
}

.topic-list a {
  color: var(--pond-green) !important;
  font-weight: 600 !important;
  font-family: var(--font-display);
}

.topic-list a:hover {
  color: var(--pond-green-mid) !important;
}

.discussion-count {
  color: var(--pond-mist) !important;
  font-size: 0.8125rem !important;
}

/* Discussions section */
.discussions-header {
  margin-bottom: var(--space-xl) !important;
}

.discussions-header h2 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--pond-ink);
}

.forum-topic .button {
  background: var(--pond-green) !important;
  border-radius: var(--radius-md) !important;
  font-family: var(--font-display) !important;
  font-weight: 600 !important;
  padding: var(--space-md) var(--space-xl) !important;
  transition: background var(--transition-fast) !important;
}

.forum-topic .button:hover {
  background: var(--pond-green-mid) !important;
}

/* Thread table */
.forum-topics-table {
  border-radius: var(--radius-lg) !important;
  box-shadow: var(--shadow-sm) !important;
  font-family: var(--font-body) !important;
}

.forum-topics-table thead {
  background: var(--pond-frost) !important;
}

.forum-topics-table th {
  color: var(--pond-slate) !important;
  font-family: var(--font-display) !important;
  font-weight: 600 !important;
  font-size: 0.8125rem !important;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  border-bottom: 2px solid var(--pond-cloud) !important;
  padding: var(--space-md) var(--space-lg) !important;
}

.forum-topics-table td {
  padding: var(--space-md) var(--space-lg) !important;
  border-bottom-color: var(--pond-frost) !important;
}

.forum-topics-table tbody tr:hover {
  background: var(--pond-frost) !important;
}

.forum-topics-table tbody tr.sticky {
  background: var(--pond-duck-light) !important;
}

.forum-topics-table .topic-title a {
  color: var(--pond-green) !important;
  font-weight: 500 !important;
  transition: color var(--transition-fast);
}

.forum-topics-table .topic-title a:hover {
  color: var(--pond-green-mid) !important;
}

.forum-topics-table .topic-author {
  color: var(--pond-slate) !important;
}

.forum-topics-table .topic-date {
  color: var(--pond-mist) !important;
}

.no-discussions {
  color: var(--pond-mist) !important;
  background: var(--pond-frost) !important;
  border-radius: var(--radius-lg) !important;
  padding: var(--space-2xl) !important;
}

/* Responsive - hide stat columns on mobile */
@media (max-width: 768px) {
  .forum-topics-table .topic-author,
  .forum-topics-table .topic-replies,
  .forum-topics-table .topic-date {
    display: none;
  }
  .forum-topics-table .topic-title {
    width: 100% !important;
  }
}
