/*
 * Forum customizations ported from the old HelpGuru child theme (style.css).
 * Only forum-relevant sections are kept; all of it loads on bbPress pages only.
 * Section numbers match the old file.
 */

/* 3.1 - White Label Login inline button in the forum sidebar */
.hg-forums #sidebar #custom_html-4 .textwidget a.btn.btn-primary {
	border: 2px solid #2e97bd !important;
	background: #2e97bd !important;
	color: #fff !important;
	font-weight: 700 !important;
	font-size: 16px !important;
	padding-left: 25px !important;
	padding-right: 25px !important;
}
.hg-forums #sidebar #custom_html-4 .textwidget a.btn.btn-primary:hover {
	border: 2px solid #185576 !important;
	background: #185576 !important;
}
.hg-forums #sidebar #custom_html-4 { background: #fff !important; padding: 0 0 40px 0; }

/* 4.1 - Forum table design */
.bbpress .bbp-forums-list .bbp-forum-title-container .bbp-forum-description br { display: none; }
.bbpress .bbp-forums-list .bbp-forum-title-container .bbp-forum-description img { float: left; margin: 10px 0 0 0; }
.bbpress .bbp-forums-list .bbp-forum-title-container .bbp-forum-description span { float: right; width: 300px; margin: 10px 0 0 0; }

.bbpress .hentry.bbp-has-subforums .bbp-forum-content br { display: block; }
.bbpress .hentry.bbp-has-subforums .bbp-forum-content img { float: none; margin: 0; }
.bbpress .hentry.bbp-has-subforums .bbp-forum-content span { float: none; width: auto; margin: 0; }

.bbpress .hentry .bbp-forum-content br { display: none; }
.bbpress .hentry .bbp-forum-content img { float: left; margin: 10px 0 0 0; }
.bbpress .hentry .bbp-forum-content span { float: right; width: 300px; margin: 10px 0 0 0; }

.bbpress.single-forum .hentry .bbp-forum-header .bbp-forum-title { font-size: 16px !important; font-weight: 300 !important; }

/* 5.1 - GD bbPress Toolbox badges (read/unread) */
.gdbbx-badge-unread-forum,
.gdbbx-badge-new-posts,
.gdbbx-badge-unread-topic,
.gdbbx-badge-new-topic {
	background-color: #ea1e21 !important;
	color: #fff !important;
	text-transform: capitalize;
	font-weight: 600;
	padding: 3px 7px !important;
	border-radius: 6px !important;
}
.gdbbx-badge-new-reply,
.gdbbx-badge-new-reply-topic {
	background-color: #f4bf4d !important;
	color: #fff !important;
	text-transform: capitalize;
	font-weight: 600;
	padding: 3px 7px !important;
	border-radius: 6px !important;
}

/* 10.1 - TinyMCE main styling (forum editor) */
.bbpress .mce-container-body, .bbpress .mce-container, .bbpress .mce-container div, .bbpress .mce-btn, .bbpress .mce-widget button {
	background-color: #32a3cb !important;
}
.bbpress .mce-toolbar .mce-ico, .bbpress .quicktags-toolbar {
	background-color: #32a3cb !important;
	color: #fff !important;
	border-color: #333 !important;
}
.bbpress .html-active .switch-html, .bbpress .tmce-active .switch-tmce, .bbpress .wp-switch-editor, .bbpress .wp-switch-editor.switch-tmce {
	background-color: #32a3cb !important;
	border-color: #333 !important;
	border-bottom: none !important;
	color: #fff !important;
}

/* 10.2 - TinyMCE dark blue background */
.bbpress .gdbbx-footer-meta { background-color: #32a3cb; }

/* 10.3 - TinyMCE text tab styling */
#bbpress-forums .bbp-the-content-wrapper input {
	animation: none;
	font-size: 12px;
	padding: 5px;
	margin: 0 2px 0 0;
	line-height: 1em;
	background-color: #32a3cb;
	color: #fff;
	font-weight: bold;
	border: none;
}
#bbpress-forums .bbp-the-content-wrapper input:hover {
	padding: 4px;
	background-color: #000;
	border-radius: 6px;
}

/* 12.0 - Code field styling */
.hg-forums .entry-content code, .hg-forums .entry-content pre {
	background: #191e23;
	display: block;
	padding: 10px;
	font-family: 'Courier Prime', Consolas, monaco, monospace;
	font-size: 13px !important;
	line-height: 20px !important;
	color: #fff;
}

/* 13.0 - bbPress avatars */
.bbp-author-avatar img {
	border: solid 2px black !important;
	padding: 2px !important;
}

/* 14.1 - Forum search form */
#bbp-search-form #bbp_search_submit {
	font-size: 17px;
	line-height: 14px;
	padding: 12px 20px;
	font-family: 'Nunito', sans-serif;
	font-weight: 700 !important;
	text-transform: capitalize !important;
	border-radius: 10px;
	vertical-align: middle;
	margin: 10px 0 40px 0;
}
input#bbp_search_submit { background-color: #4b4d4d; color: #fff; }
#bbpress-forums .bbp-search-form { float: none !important; }
#bbpress-forums .bbp-search-form > form > div { display: flex; }
#bbpress-forums .bbp-search-form > form input#bbp_search {
	width: 80% !important;
	margin: 10px 10px 40px 10px !important;
}

/* 16.1 - Hide WP tag links (as on the old site: nofollow links in posts are not clickable) */
#primary #content .entry-content a[rel~=nofollow] { pointer-events: none; color: #444; }
#primary #content .entry-content #bbpress-forums .bbp-topic-controls a[rel~=nofollow] {
	pointer-events: auto !important;
	color: #fff !important;
}
.topic.bbpress #primary #content .entry-content a[rel~=nofollow] {
	pointer-events: auto !important;
	color: #39c !important;
}

/* 17.0 - bbPress RSS widget */
.hg-forums .widget_rss li > a {
	font-size: 13px !important;
	line-height: 20px !important;
	margin: 0 0 15px;
}

/* ---------- KnowAll fit (added) ---------- */

/* No white gap between the site header and the blue forum header
   (block themes put a "block gap" margin above each section). */
.wp-site-blocks > .hg-forums,
.wp-site-blocks > .hg-forums + * { margin-block-start: 0 !important; }

/* Forum search button: white text */
.hg-forums #bbpress-forums #bbp_search_submit,
.hg-forums #bbpress-forums #bbp-search-form input[type="submit"] { color: #fff !important; }

/* Sidebar search widget button: white text */
.hg-forums #sidebar .wp-block-search__button,
.hg-forums #sidebar input[type="submit"] { color: #fff !important; }

/* Topic image tiles in the topic list: a bit larger */
.hg-forums #bbpress-forums li.bbp-topic-title img:not(.avatar):not(.emoji):not(.wp-smiley) {
	width: 96px !important;
	max-width: 96px !important;
	height: auto !important;
}
