/* Comprehension-checkpoint panel. Sized for iPad landscape, high contrast. */

.cp-overlay {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 3vh 3vw;
	background: rgba(12, 14, 24, 0.82);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
	color: #f4f1ea;
	-webkit-tap-highlight-color: transparent;
}

.cp-panel {
	box-sizing: border-box;
	width: min(980px, 100%);
	max-height: 94vh;
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
	padding: 28px 34px 30px;
	border-radius: 18px;
	background: #232842;
	border: 1px solid #3d4468;
	box-shadow: 0 18px 60px rgba(0, 0, 0, 0.5);
	font-size: 19px;
	line-height: 1.4;
	text-align: left;
}

.cp-head { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.cp-tag {
	font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase;
	color: #f0c987; font-weight: 700;
}
.cp-draft {
	font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase;
	padding: 2px 8px; border-radius: 999px; border: 1px solid #8a8fb0; color: #b8bcd6;
}
.cp-title { margin: 0 0 8px; font-size: 27px; line-height: 1.2; font-weight: 700; color: #fff; }
.cp-prompt { margin: 0 0 18px; color: #e6e3dc; }

.cp-options { display: grid; gap: 10px; }
.cp-opt {
	display: flex; gap: 14px; align-items: flex-start; text-align: left;
	width: 100%; padding: 14px 16px; border-radius: 12px;
	background: #2e3556; border: 2px solid #46507d; color: #f4f1ea;
	font: inherit; cursor: pointer; min-height: 56px;
}
.cp-opt:hover:not(:disabled) { border-color: #f0c987; background: #353d63; }
.cp-letter {
	flex: none; width: 30px; height: 30px; border-radius: 50%;
	display: inline-flex; align-items: center; justify-content: center;
	background: #46507d; font-weight: 700; font-size: 16px;
}
.cp-opt.is-correct { border-color: #6fd08c; background: #20432f; }
.cp-opt.is-correct .cp-letter { background: #6fd08c; color: #0d2415; }
.cp-opt.is-wrong { border-color: #d86b6b; background: #432628; opacity: 0.75; }
.cp-opt:disabled { cursor: default; }

.cp-note { min-height: 1.4em; margin: 12px 0 0; color: #f0c987; }

.cp-feedback {
	margin-top: 14px; padding: 16px 18px; border-radius: 12px;
	background: #1a1e35; border: 1px solid #46507d;
}
.cp-feedback ul { margin: 10px 0 0; padding-left: 22px; }
.cp-feedback[hidden] { display: none; }

.cp-actions { display: flex; justify-content: flex-end; margin-top: 12px; }
.cp-btn {
	font: inherit; font-weight: 700; padding: 12px 26px; border-radius: 999px;
	border: 2px solid #f0c987; background: transparent; color: #f0c987; cursor: pointer;
	min-height: 48px;
}
.cp-btn--primary { background: #f0c987; color: #1d2030; }
.cp-btn:disabled { opacity: 0.4; cursor: default; }
.cp-feedback .cp-btn { display: block; margin: 14px 0 0 auto; }

/* evidence type */
.cp-ev-key { margin-bottom: 12px; padding: 12px 16px; border-radius: 12px; background: #1a1e35; }
.cp-ev-key p { margin: 4px 0; }
.cp-evidence { display: grid; gap: 6px; }
.cp-ev-row {
	display: grid; grid-template-columns: 1fr 92px 92px; align-items: center; gap: 10px;
	padding: 9px 12px; border-radius: 10px; background: #2e3556; border: 2px solid transparent;
}
.cp-ev-row--head { background: transparent; font-size: 14px; color: #b8bcd6; padding-top: 0; padding-bottom: 0; }
.cp-ev-pick { text-align: center; }
.cp-ev-pick input { width: 26px; height: 26px; accent-color: #f0c987; }
.cp-ev-row.is-model { border-color: #6fd08c; }

/* edit type */
.cp-edit { display: grid; gap: 4px; }
.cp-edit-row {
	display: grid; grid-template-columns: 30px 1fr 260px; align-items: center; gap: 10px;
	padding: 3px 12px; border-radius: 10px; background: #2e3556; border: 2px solid transparent;
}
.cp-edit-row.is-fixed { background: #262b49; color: #c9ccdf; }
.cp-edit-row.is-right { border-color: #6fd08c; }
.cp-edit-row.is-wrong { border-color: #d86b6b; }
.cp-edit-n { font-size: 14px; color: #b8bcd6; text-align: right; }
.cp-edit-text { font-family: Georgia, "Times New Roman", serif; font-size: 18px; }
.cp-edit-answer { display: flex; align-items: center; gap: 10px; justify-content: flex-end; }
.cp-edit-given { font-size: 13px; color: #8a8fb0; }
.cp-edit-tick { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.cp-edit-tick input { width: 24px; height: 24px; accent-color: #f0c987; }
.cp-edit-word {
	width: 150px; padding: 5px 10px; border-radius: 8px; border: 2px solid #46507d;
	background: #141831; color: #fff; font: inherit; font-size: 16px;
}
.cp-edit-word:focus { outline: none; border-color: #f0c987; }
.cp-edit-key { grid-column: 2 / -1; font-size: 15px; color: #cfe9d6; }
.cp-edit-key s { color: #f2a0a0; }
.cp-edit-key em { color: #b8bcd6; margin-left: 6px; }

@media (max-width: 760px) {
	.cp-panel { padding: 20px 18px; font-size: 17px; }
	.cp-ev-row { grid-template-columns: 1fr 64px 64px; }
	.cp-edit-row { grid-template-columns: 24px 1fr; }
	.cp-edit-answer { grid-column: 2; justify-content: flex-start; }
}
