/**
 * AI Assistant — single-submission "Summarize with AI" styles.
 */

.afb-ai-summarize-wrap {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
}

.afb-ai-summarize-btn .dashicons,
.afb-ai-draft-btn .dashicons {
	color: #6d4aff;
	vertical-align: text-bottom;
}

.afb-ai-mode-toggle {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	font-size: 12px;
	color: #50575e;
}

.afb-ai-mode-option {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	cursor: pointer;
	white-space: nowrap;
}

.afb-ai-mode-option input {
	margin: 0;
}

.afb-ai-summarize-btn.is-loading {
	opacity: 0.7;
	cursor: progress;
}

.afb-ai-summary-panel {
	margin: 16px 0 24px;
	padding: 20px 22px;
	background: #fff;
	border: 1px solid #e2e4e9;
	border-left: 4px solid #6d4aff;
	border-radius: 10px;
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.afb-ai-summary-panel .afb-ai-summary-head {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 10px;
	font-size: 15px;
	font-weight: 600;
	color: #1d2327;
}

.afb-ai-summary-panel .afb-ai-summary-head .dashicons {
	color: #6d4aff;
}

.afb-ai-summary-panel .afb-ai-summary-body {
	white-space: pre-wrap;
	line-height: 1.6;
	color: #2c3338;
}

.afb-ai-summary-panel .afb-ai-summary-meta {
	margin-top: 12px;
	padding-top: 10px;
	border-top: 1px solid #f0f0f1;
	font-size: 12px;
	color: #646970;
}

.afb-ai-summary-panel.afb-ai-summary-error {
	border-left-color: #b32d2e;
}

.afb-ai-summary-panel.afb-ai-summary-error .afb-ai-summary-head .dashicons {
	color: #b32d2e;
}

.afb-ai-spinner {
	display: inline-block;
	width: 16px;
	height: 16px;
	margin-right: 4px;
	border: 2px solid rgba(109, 74, 255, 0.3);
	border-top-color: #6d4aff;
	border-radius: 50%;
	vertical-align: text-bottom;
	animation: afb-ai-spin 0.7s linear infinite;
}

@keyframes afb-ai-spin {
	to {
		transform: rotate( 360deg );
	}
}

/* Draft reply panel */
.afb-ai-reply-panel {
	margin: 16px 0 24px;
	padding: 20px 22px;
	background: #fff;
	border: 1px solid #e2e4e9;
	border-left: 4px solid #6d4aff;
	border-radius: 10px;
	box-shadow: 0 1px 2px rgba( 0, 0, 0, 0.04 );
}

.afb-ai-reply-panel.afb-ai-summary-error {
	border-left-color: #b32d2e;
}

.afb-ai-reply-hint {
	margin: 0 0 8px;
	font-size: 12px;
	color: #646970;
}

.afb-ai-reply-body {
	width: 100%;
	box-sizing: border-box;
	font-family: inherit;
	line-height: 1.6;
}

/* Regenerate footer + meta note (shared) */
.afb-ai-summary-foot {
	margin-top: 10px;
}

.afb-ai-regenerate.is-loading {
	opacity: 0.7;
	cursor: progress;
}

.afb-ai-summary-foot .afb-ai-copy {
	margin-left: 12px;
}

.afb-ai-copied {
	margin-left: 8px;
	font-size: 12px;
	font-weight: 600;
	color: #1a7f37;
}

.afb-ai-draft-wrap {
	display: inline-flex;
	flex-direction: column;
	gap: 6px;
}

.afb-ai-reply-instructions {
	min-width: 260px;
	max-width: 420px;
	font-family: inherit;
	font-size: 13px;
}
