/* CBZ Commenti dal Forum — si adatta ai colori del tema (chiaro e scuro). */

.cbzfc {
	--cbzfc-accent: #f2711c;
	--cbzfc-accent-text: #fff;
	--cbzfc-line: color-mix(in srgb, currentColor 14%, transparent);
	--cbzfc-soft: color-mix(in srgb, currentColor 6%, transparent);
	--cbzfc-muted: color-mix(in srgb, currentColor 62%, transparent);
	clear: both;
	margin: 2.5rem 0 1.5rem;
}

.cbzfc-head {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: .75rem 1rem;
	padding-bottom: .9rem;
	margin-bottom: .25rem;
	border-bottom: 1px solid var(--cbzfc-line);
}

.cbzfc .cbzfc-title {
	display: flex;
	align-items: center;
	gap: .55rem;
	margin: 0;
	font-size: 1.35rem;
	line-height: 1.2;
}

.cbzfc-count {
	min-width: 1.7em;
	padding: .2em .55em;
	border-radius: 999px;
	background: var(--cbzfc-accent);
	color: var(--cbzfc-accent-text);
	font-size: .75rem;
	font-weight: 700;
	line-height: 1.2;
	text-align: center;
}

.cbzfc .cbzfc-btn {
	display: inline-flex;
	align-items: center;
	gap: .4rem;
	padding: .55rem 1.05rem;
	border: 1px solid var(--cbzfc-accent);
	border-radius: 999px;
	background: var(--cbzfc-accent);
	color: var(--cbzfc-accent-text);
	font-size: .9rem;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	transition: filter .15s ease, background-color .15s ease;
}
.cbzfc .cbzfc-btn:hover,
.cbzfc .cbzfc-btn:focus-visible { filter: brightness(1.08); color: var(--cbzfc-accent-text); }

.cbzfc .cbzfc-btn--ghost {
	background: transparent;
	color: inherit;
	border-color: var(--cbzfc-line);
}
.cbzfc .cbzfc-btn--ghost:hover,
.cbzfc .cbzfc-btn--ghost:focus-visible { background: var(--cbzfc-soft); color: inherit; filter: none; }

.cbzfc .cbzfc-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.cbzfc .cbzfc-item {
	display: grid;
	grid-template-columns: 48px minmax(0, 1fr);
	gap: .9rem;
	margin: 0;
	padding: 1.15rem 0;
	border-bottom: 1px solid var(--cbzfc-line);
}
.cbzfc .cbzfc-item::before,
.cbzfc .cbzfc-item::marker { content: none; }
.cbzfc .cbzfc-item:last-child { border-bottom: 0; }

.cbzfc .cbzfc-avatar {
	display: block;
	width: 48px;
	height: 48px;
	margin: 0;
	border-radius: 50%;
	object-fit: cover;
	object-position: top;
	background: var(--cbzfc-soft);
}
.cbzfc .cbzfc-avatar[hidden] { display: none !important; }
.cbzfc-avatar--empty:not([hidden]) {
	display: flex !important;
	align-items: center;
	justify-content: center;
	font-weight: 700;
	color: var(--cbzfc-muted);
}

.cbzfc-meta {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: .2rem .65rem;
	margin-bottom: .35rem;
}
.cbzfc .cbzfc-author {
	color: inherit;
	font-weight: 700;
	text-decoration: none;
}
.cbzfc .cbzfc-author:hover { color: var(--cbzfc-accent); }
.cbzfc .cbzfc-date {
	color: var(--cbzfc-muted);
	font-size: .82rem;
	text-decoration: none;
}
.cbzfc .cbzfc-date:hover { text-decoration: underline; }

.cbzfc-content {
	font-size: .97rem;
	line-height: 1.65;
	overflow-wrap: anywhere;
}
.cbzfc-content > :first-child { margin-top: 0; }
.cbzfc-content > :last-child { margin-bottom: 0; }
.cbzfc-content a { color: var(--cbzfc-accent); }
.cbzfc-content img { max-width: 100%; height: auto; vertical-align: middle; }
.cbzfc-content img.cbzfc-emo { width: auto; height: 1.4em; vertical-align: -.3em; }
.cbzfc-content iframe {
	display: block;
	width: 100%;
	max-width: 560px;
	height: auto;
	aspect-ratio: 16 / 9;
	margin: .6rem 0;
	border: 0;
}

.cbzfc .cbzfc-quote {
	margin: .2rem 0 .8rem;
	padding: .6rem .9rem;
	border: 0;
	border-left: 3px solid var(--cbzfc-accent);
	border-radius: 0 8px 8px 0;
	background: var(--cbzfc-soft);
	font-size: .93em;
	font-style: normal;
	quotes: none;
}
.cbzfc .cbzfc-quote::before,
.cbzfc .cbzfc-quote::after { content: none !important; display: none !important; }
.cbzfc .cbzfc-quote .cbzfc-quote { border-left-color: var(--cbzfc-line); }
.cbzfc .cbzfc-quote cite {
	display: block;
	margin-bottom: .2rem;
	color: var(--cbzfc-muted);
	font-size: .85em;
	font-style: normal;
	font-weight: 600;
}

.cbzfc-spoiler {
	margin: .4rem 0 .8rem;
	padding: .5rem .8rem;
	border: 1px dashed var(--cbzfc-line);
	border-radius: 8px;
}
.cbzfc-spoiler summary { cursor: pointer; font-weight: 600; }
.cbzfc-spoiler[open] summary { margin-bottom: .4rem; }

.cbzfc-code {
	margin: .4rem 0 .8rem;
	padding: .6rem .8rem;
	border-radius: 6px;
	background: var(--cbzfc-soft);
	font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
	font-size: .86em;
	overflow-x: auto;
}

.cbzfc-empty,
.cbzfc-note {
	margin: 1rem 0;
	color: var(--cbzfc-muted);
}

.cbzfc-foot {
	margin-top: .75rem;
	text-align: center;
}

@media (max-width: 600px) {
	.cbzfc .cbzfc-item { grid-template-columns: 38px minmax(0, 1fr); gap: .7rem; }
	.cbzfc .cbzfc-avatar { width: 38px; height: 38px; }
	.cbzfc .cbzfc-title { font-size: 1.2rem; }
}
