.sego-subtopics {
	clear: both;
	margin: .65rem 0 0;
	font-size: .9em;
}

.sego-subtopics__actions {
	display: flex;
	align-items: center;
	gap: .45rem;
	min-height: 1.8rem;
	color: inherit;
}

.sego-subtopics__toggle {
	padding: 0;
	border: 0;
	background: transparent;
	color: inherit;
	font: inherit;
	font-size: 11px;
	cursor: pointer;
	text-decoration: none;
}

.sego-subtopics__toggle:hover {
	text-decoration: underline;
}

.sego-subtopics__content {
	margin: .5rem 0 0 1.25rem;
}

.sego-subtopics__posts {
	display: block;
}

.sego-subtopics__post {
	padding: .75rem 12px;
	border-bottom: 1px solid rgba(127, 127, 127, .25);
}

.sego-subtopics__meta {
	display: flex;
	flex-wrap: wrap;
	gap: .45rem;
	align-items: baseline;
	margin-bottom: .25rem;
}

.sego-subtopics__date {
	opacity: .65;
	font-size: .9em;
}

.sego-subtopics__message {
	margin-top: .4rem;
	overflow-wrap: anywhere;
}

.sego-subtopics__message img {
	max-width: 100%;
	height: auto;
}

.sego-subtopics__attachments {
	margin-top: .45rem;
}

.sego-subtopics__form {
	display: grid;
	gap: .55rem;
	margin: .65rem 0 0 1.25rem;
	padding: .5rem;
	border: 1px solid rgba(127, 127, 127, .25);
	background: rgba(127, 127, 127, .04);
}

.sego-subtopics__label,
.sego-subtopics__file {
	display: grid;
	gap: .3rem;
}

.sego-subtopics__label textarea {
	width: 100%;
	box-sizing: border-box;
	resize: vertical;
	min-height: 12rem;
	padding: .45rem;
	font-size: 1rem;
	line-height: 1.5;
}

.sego-subtopics__form textarea:focus {
	outline: 2px solid currentColor;
	outline-offset: 1px;
	box-shadow: none;
}

.sego-subtopics__bbcode {
	display: flex;
	position: relative;
	flex-wrap: wrap;
	align-items: center;
	gap: .25rem;
}

.sego-subtopics__bbcode-button,
.sego-subtopics__smiley {
	padding: .15rem .4rem;
	border: 1px solid rgba(127, 127, 127, .25);
	background: transparent;
	color: inherit;
	font: inherit;
	cursor: pointer;
}

.sego-subtopics__bbcode-button {
	min-width: 2rem;
	min-height: 2rem;
	font-size: 1rem;
}

.sego-subtopics__form-actions button {
	padding: .3rem .6rem;
	font-size: 1rem;
}

.sego-subtopics__bbcode-button:hover,
.sego-subtopics__smiley:hover {
	background: rgba(127, 127, 127, .08);
}

.sego-subtopics__smilies {
	position: absolute;
	top: calc(100% + .25rem);
	left: 0;
	z-index: 10;
	display: flex;
	flex-wrap: wrap;
	gap: .25rem;
	max-width: min(28rem, calc(100vw - 2rem));
	max-height: 12rem;
	overflow-y: auto;
	padding: .35rem;
	border: 1px solid rgba(127, 127, 127, .35);
	background: var(--sego-modern-card-background-color, #fff);
	box-shadow: 0 2px 8px rgba(0, 0, 0, .12);
}

.sego-subtopics__smilies[hidden] {
	display: none !important;
}

.sego-subtopics__form-actions {
	display: flex;
	gap: .45rem;
}

.sego-subtopics__error {
	margin: 0;
	color: #b21f2d;
}

.sego-subtopics__no-replies {
	margin: 0 0 .55rem;
	opacity: .7;
}

@media (max-width: 700px) {
	.sego-subtopics__content,
	.sego-subtopics__form {
		margin-inline-start: .5rem;
	}
}

/* Match the flat message treatment used by Modern without changing its post geometry. */
.sego-modern-layout .sego-subtopics__content {
	margin-inline-start: 3rem;
}

.sego-modern-layout .sego-subtopics__posts {
	color: inherit;
	border-left: 2px solid #B8B8B8;
}

.sego-modern-layout .sego-subtopics__post {
	padding: .75rem 29px;
	border-bottom-color: var(--sego-modern-card-border-color, #d7e0e8);
}

.sego-modern-layout .sego-subtopics__meta {
	margin-bottom: 0;
	font-size: 8.5px;
	line-height: 1.5;
	font-weight: 400;
}

.sego-modern-layout .sego-subtopics__meta > span:first-child {
	font-weight: 700;
}

.sego-modern-layout .sego-subtopics__date {
	color: inherit;
	opacity: .65;
	font-size: 8.5px;
}

.sego-modern-layout .sego-subtopics__message {
	margin-top: .4rem;
	font-size: 13px;
	line-height: 1.5;
}

.sego-subtopics__post-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: .75rem;
}

.sego-subtopics__actions {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	gap: 4px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.sego-subtopics__action {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 20px;
	height: 20px;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	color: #74808d;
	font-size: 12px;
	cursor: pointer;
}

.sego-subtopics__action,
.sego-subtopics__action:hover,
.sego-subtopics__action:focus {
	text-decoration: none;
}

.sego-subtopics__action:hover,
.sego-subtopics__action:focus {
	background: transparent;
	box-shadow: none;
	color: #D31141;
}

.sego-subtopics__edit-form {
	margin-top: .4rem;
}

.sego-subtopics__edit-text {
	display: block;
	width: 100%;
	box-sizing: border-box;
	resize: vertical;
}

.sego-subtopics__edit-actions {
	display: flex;
	gap: .45rem;
	margin-top: .45rem;
}

.sego-subtopics__edit-error {
	margin: .45rem 0 0;
	color: #b21f2d;
}

.sego-subtopics__smiley img {
	display: block;
	width: auto;
	height: 20px;
	max-width: 24px;
	object-fit: contain;
}
