/* CM Portal song components. Matches the site's existing blue (#0073aa) and navy (#060992). */
:root {
	--cmp-ink: #1d2433;
	--cmp-muted: #5b6475;
	--cmp-line: #dfe3ea;
	--cmp-soft: #f3f6fb;
	--cmp-blue: #0073aa;
	--cmp-navy: #060992;
	--cmp-stage: #0f1f5c;
	--cmp-stage-text: #ffffff;
	--cmp-stage-muted: #b8c2e8;
}

.cmp-song .lyrics-content,
.cmp-song .cmp-panel { font-family: "Anek Telugu", system-ui, sans-serif; line-height: 1.75; }

/* Song details card */
.cmp-song-card {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
	gap: 12px 24px;
	margin: 0 0 20px;
	padding: 16px 18px;
	background: var(--cmp-soft);
	border-left: 4px solid var(--cmp-blue);
	border-radius: 4px;
}
.cmp-song-card div { margin: 0; }
.cmp-song-card dt { font: 600 13px/1.3 "Instrument Sans", system-ui, sans-serif; color: var(--cmp-muted); margin: 0 0 2px; }
.cmp-song-card dd { font: 500 16px/1.35 "Instrument Sans", "Anek Telugu", system-ui, sans-serif; color: var(--cmp-ink); margin: 0; }

/* Tools */
.cmp-song-tools { display: flex; gap: 10px; margin: 0 0 16px; }
.cmp-project {
	font: 600 15px/1 "Instrument Sans", system-ui, sans-serif;
	padding: 11px 16px;
	color: #fff;
	background: var(--cmp-navy);
	border: 0;
	border-radius: 6px;
	cursor: pointer;
}
.cmp-project:hover { background: #0a0fb8; }

/* Tabs */
.cmp-tabs { display: flex; gap: 4px; box-shadow: inset 0 -2px 0 var(--cmp-line); margin: 8px 0 18px; overflow-x: auto; }
.cmp-tabs [role="tab"] {
	font: 600 15px/1 "Instrument Sans", "Anek Telugu", system-ui, sans-serif;
	padding: 12px 16px;
	color: var(--cmp-muted);
	background: none;
	border: 0;
	cursor: pointer;
	white-space: nowrap;
}
.cmp-tabs [aria-selected="true"] { color: var(--cmp-ink); box-shadow: inset 0 -3px 0 var(--cmp-blue); }
.cmp-plain { white-space: normal; }
.cmp-chords {
	font: 15px/1.6 ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
	background: var(--cmp-soft);
	padding: 16px;
	border-radius: 4px;
	overflow-x: auto;
	white-space: pre;
}

/* Related songs */
.cmp-related { margin: 32px 0 8px; padding-top: 20px; border-top: 1px solid var(--cmp-line); }
.cmp-related h2 { font: 700 20px/1.3 "Bricolage Grotesque", "Anek Telugu", system-ui, sans-serif; margin: 0 0 12px; }
.cmp-related ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 2px 24px; }
.cmp-related li { margin: 0; padding: 8px 0; border-bottom: 1px solid var(--cmp-line); }
.cmp-related a { font-family: "Anek Telugu", "Instrument Sans", system-ui, sans-serif; text-decoration: none; color: var(--cmp-blue); }
.cmp-related a:hover { text-decoration: underline; }

.cmp-song :focus-visible, .cmp-projector :focus-visible { outline: 3px solid #ffb703; outline-offset: 2px; }

/* Copy button (moved from header.php) */
.copy-btn { float: right; margin-bottom: 10px; padding: 6px 12px; background: var(--cmp-blue); color: #fff; border: 0; border-radius: 4px; cursor: pointer; }
.copy-btn:hover { background: #005177; }
.copy-btn.copied { background: #28a745; }

/* Projection mode: the one bold moment, built for a church projector */
html.cmp-projecting, html.cmp-projecting body { overflow: hidden; }
.cmp-projector {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: grid;
	grid-template-rows: auto 1fr auto;
	background: var(--cmp-stage);
	color: var(--cmp-stage-text);
	padding: max(16px, env(safe-area-inset-top)) 4vw max(16px, env(safe-area-inset-bottom));
}
.cmp-projector[hidden] { display: none; }
.cmp-projector-title { margin: 0; font: 600 clamp(14px, 1.6vw, 22px)/1.3 "Anek Telugu", system-ui, sans-serif; color: var(--cmp-stage-muted); }
.cmp-projector-text {
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	white-space: pre-line;
	overflow: hidden;
	min-height: 0;
	font-family: "Anek Telugu", system-ui, sans-serif;
	font-weight: 600;
	line-height: 1.45;
	cursor: pointer;
}
.cmp-projector-bar { display: flex; align-items: center; justify-content: center; gap: 12px; }
.cmp-projector-bar button {
	font: 600 15px/1 "Instrument Sans", system-ui, sans-serif;
	padding: 10px 16px;
	color: var(--cmp-stage-text);
	background: rgba(255, 255, 255, .12);
	border: 1px solid rgba(255, 255, 255, .25);
	border-radius: 6px;
	cursor: pointer;
}
.cmp-projector-bar button[data-a="close"] { margin-left: 16px; }
.cmp-projector-count { min-width: 64px; text-align: center; font: 500 15px/1 "Instrument Sans", system-ui, sans-serif; color: var(--cmp-stage-muted); }

@media (max-width: 600px) {
	.cmp-projector-bar button[data-a="close"] { margin-left: 4px; }
}
@media (prefers-reduced-motion: no-preference) {
	.cmp-projector-text { transition: opacity .15s; }
}
