/* ==========================================================================
   Color Align Conservation — Tool-specific styles
   Shared Benchling-style framework: tools/common/tbb-sequence-tools.css
   ========================================================================== */

/* ── Sequence input textarea ─────────────────────────────────────────────── */
.tbb-color-align-cons .tbb-cac-seq-input {
	min-height: 160px;
	font-family: var(--tbb-seq-font-mono);
	font-size:   12px;
}

/* ── Similarity groups textarea ──────────────────────────────────────────── */
.tbb-color-align-cons .tbb-cac-groups-input {
	min-height: 52px;
	font-family: var(--tbb-seq-font-mono);
	font-size:   13px;
}

/* ── Starting positions textarea ─────────────────────────────────────────── */
.tbb-color-align-cons .tbb-cac-starts-input {
	min-height: 42px;
	font-family: var(--tbb-seq-font-mono);
	font-size:   13px;
}

/* ── Options row ─────────────────────────────────────────────────────────── */
.tbb-cac-options {
	display:   flex;
	flex-wrap: wrap;
	gap:       12px 24px;
	margin:    0 0 4px;
}

.tbb-cac-option {
	display:     flex;
	align-items: center;
	gap:         8px;
	font-size:   13px;
	color:       var(--tbb-seq-text);
}

.tbb-cac-option label {
	font-weight: 500;
	white-space: nowrap;
}

.tbb-cac-option select {
	padding:       4px 8px;
	border:        1px solid var(--tbb-seq-border);
	border-radius: 4px;
	background:    var(--tbb-seq-bg);
	color:         var(--tbb-seq-text);
	font-size:     13px;
	cursor:        pointer;
}

.tbb-cac-option select:focus {
	outline:        2px solid var(--tbb-seq-accent);
	outline-offset: 1px;
}

/* ── Coloured alignment output container ─────────────────────────────────── */
/*
 * NOTE: this is a <div> (not <pre>) because it receives innerHTML.
 * white-space: pre preserves the newlines and spaces written by the JS.
 */
.tbb-cac-output {
	font-family:  var(--tbb-seq-font-mono);
	font-size:    13px;
	line-height:  1.5;
	white-space:  pre;
	overflow-x:   auto;
	overflow-y:   auto;
	max-height:   560px;
	padding:      0.75rem;
	background:   var(--tbb-seq-bg);
	border:       1px solid var(--tbb-seq-border);
	border-radius: 4px;
	word-break:   normal;
	word-wrap:    normal;
}

/* ── Conservation colour spans — BACKGROUND mode (default) ──────────────── */
.tbb-cac-output .cac-ident {
	background-color: #000;
	color:            #fff;
}

.tbb-cac-output .cac-sim {
	background-color: #888;
	color:            #fff;
}

.tbb-cac-output .cac-diff {
	/* no highlight */
}

/* ── Conservation colour spans — TEXT mode ───────────────────────────────── */
.tbb-cac-output.tbb-cac-text .cac-ident {
	background-color: transparent;
	color:            #000;
	font-weight:      700;
}

.tbb-cac-output.tbb-cac-text .cac-sim {
	background-color: transparent;
	color:            #777;
}

.tbb-cac-output.tbb-cac-text .cac-diff {
	background-color: transparent;
	color:            #bbb;
}

/* ── Wider output on large screens ──────────────────────────────────────── */
@media ( min-width: 900px ) {
	.tbb-color-align-cons .tbb-cac-output {
		max-height: 640px;
	}
}
