/* Community page custom styles - unify with JOHTA/Dashboard look and feel */

/* Section titles (align to JOHTA) */
.dashboard-main-content .section-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-color);
  margin: 10px 0 18px;
  padding-bottom: 10px;
  border-bottom: 3px solid var(--primary-color);
}

/* Tabs */
.community-nav-section {
  margin-bottom: 18px;
}
.community-nav-tabs {
  display: flex;
  gap: 12px;
}
.community-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  background: var(--white);
  border: 1px solid var(--border-color);
  color: var(--text-color);
  text-decoration: none;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(0,0,0,.04);
}
.community-tab:hover {
  background: #E8F4F4;
  border-color: #D6EEEE;
}

/* Stats */
.community-stats .stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.stat-card {
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0,0,0,.04);
}
.stat-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: #E8F4F4;
  margin: 0 auto 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
}
.stat-number {
  font-size: 24px;
  font-weight: 800;
  color: var(--primary-color);
  margin-bottom: 4px;
}
.stat-label {
  font-size: 12px;
  color: var(--light-text);
}

/* Recent Topics */
.recent-topics .topics-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
.topic-item {
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 14px;
  display: grid;
  grid-template-columns: 56px 1fr auto;
  gap: 14px;
  align-items: start;
  box-shadow: 0 2px 8px rgba(0,0,0,.04);
}
.topic-avatar .avatar-placeholder {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #E8F4F4;
  color: var(--primary-color);
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}
.topic-content .topic-title {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-color);
}
.topic-content .topic-excerpt {
  margin: 0 0 8px;
  font-size: 14px;
  color: var(--light-text);
  line-height: 1.55;
}
.topic-meta {
  display: flex;
  gap: 12px;
  font-size: 12px;
  color: var(--light-text);
}
.topic-stats {
  display: flex;
  align-items: center;
  gap: 10px;
}
.topic-stats .stat-item {
  text-align: center;
  background: var(--secondary-color);
  border-radius: 8px;
  padding: 8px 10px;
  min-width: 58px;
}
.topic-stats .stat-number {
  display: block;
  font-weight: 800;
  color: var(--primary-color);
}
.topic-stats .stat-label {
  font-size: 11px;
  color: var(--light-text);
}

/* Active Members */
.active-members .members-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.member-card {
  position: relative;
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 14px;
  display: flex;
  gap: 12px;
  align-items: center;
  box-shadow: 0 2px 8px rgba(0,0,0,.04);
}
.member-avatar .avatar-placeholder {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #E8F4F4;
  color: var(--primary-color);
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}
.member-info .member-name {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-color);
}
.member-info .member-specialty {
  margin: 0 0 2px;
  font-size: 13px;
  color: var(--light-text);
}
.member-info .member-posts {
  font-size: 12px;
  color: var(--light-text);
}
.member-status {
  position: absolute;
  right: 10px;
  top: 10px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.member-status.online { background: #2E7D32; }
.member-status.away { background: #F57C00; }

/* Buttons/Links */
.view-more-link {
  display: inline-block;
  margin-top: 12px;
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 700;
  border: 2px solid var(--primary-color);
  border-radius: 8px;
  padding: 8px 14px;
}
.view-more-link:hover {
  background: var(--primary-color);
  color: var(--white);
}

/* Responsive */
@media (max-width: 992px) {
  .community-stats .stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .active-members .members-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 576px) {
  .community-nav-tabs {
    flex-wrap: wrap;
  }
  .community-stats .stats-grid,
  .active-members .members-grid {
    grid-template-columns: 1fr;
  }
  .topic-item {
    grid-template-columns: 48px 1fr;
  }
  .topic-stats {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
}
