/* Fixlight admin screens. Uses WordPress admin colours so it fits every admin colour scheme. */

.fixlight-wrap {
	max-width: 1100px;
}

.fixlight-tabs {
	margin-bottom: 16px;
}

.fixlight-lede {
	font-size: 14px;
	max-width: 70ch;
}

.fixlight-card {
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	padding: 16px 20px;
	margin: 16px 0;
}

.fixlight-card h2 {
	margin-top: 0;
}

.fixlight-score-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 16px 24px;
}

.fixlight-score-box {
	display: flex;
	flex-direction: column;
	align-items: center;
	min-width: 120px;
}

.fixlight-score-label {
	font-size: 13px;
	color: #50575e;
}

.fixlight-score-number {
	font-size: 48px;
	font-weight: 600;
	line-height: 1.1;
}

.fixlight-score-before {
	color: #50575e;
}

.fixlight-score-after {
	color: #007017;
}

.fixlight-score-arrow {
	font-size: 32px;
	color: #50575e;
}

.fixlight-stats {
	margin: 0 0 0 16px;
	list-style: disc;
	padding-left: 16px;
}

.fixlight-note {
	color: #50575e;
	max-width: 75ch;
}

.fixlight-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	align-items: center;
	margin: 16px 0 8px;
}

.fixlight-progress progress {
	width: 100%;
	max-width: 480px;
	height: 16px;
}

.fixlight-progress p:empty {
	margin: 0;
}

/* The pages being checked load here, off-screen but at desktop size. */
.fixlight-scan-stage {
	position: absolute;
	left: -10000px;
	top: 0;
	width: 1280px;
	height: 900px;
	overflow: hidden;
}

.fixlight-scan-stage iframe {
	width: 1280px;
	height: 900px;
	border: 0;
}

.fixlight-issues {
	margin-top: 24px;
}

.fixlight-issue {
	background: #fff;
	border: 1px solid #c3c4c7;
	border-left-width: 4px;
	border-radius: 4px;
	margin: 8px 0;
}

.fixlight-issue-open {
	border-left-color: #d63638;
}

.fixlight-issue-partial {
	border-left-color: #dba617;
}

.fixlight-issue-fixed {
	border-left-color: #00a32a;
}

.fixlight-issue summary {
	cursor: pointer;
	padding: 12px 16px;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 12px;
}

.fixlight-issue summary:focus-visible {
	outline: 2px solid #2271b1;
	outline-offset: -2px;
}

.fixlight-issue-title {
	font-weight: 600;
	font-size: 14px;
}

.fixlight-issue-meta {
	color: #50575e;
	flex-basis: 100%;
}

.fixlight-badge {
	display: inline-block;
	border-radius: 10px;
	padding: 1px 8px;
	font-size: 12px;
	font-weight: 600;
}

.fixlight-badge-open {
	background: #fcf0f1;
	color: #8a2424;
}

.fixlight-badge-partial {
	background: #fcf9e8;
	color: #614d00;
}

.fixlight-badge-fixed {
	background: #edfaef;
	color: #005c12;
}

.fixlight-issue-body {
	padding: 0 16px 12px;
	max-width: 80ch;
}

.fixlight-issue-body h3 {
	font-size: 13px;
	margin: 12px 0 4px;
}

.fixlight-examples code {
	display: block;
	margin-top: 2px;
	white-space: pre-wrap;
	word-break: break-all;
	font-size: 12px;
}

.fixlight-fixes {
	max-width: 80ch;
}

.fixlight-fix {
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	padding: 12px 16px;
	margin: 8px 0;
}

.fixlight-fix label {
	font-weight: 600;
}

.fixlight-fix .description {
	margin: 4px 0 0 24px;
}

.fixlight-images td {
	vertical-align: top;
}

.fixlight-image-cell {
	display: flex;
	gap: 12px;
	align-items: flex-start;
}

.fixlight-image-cell img {
	border-radius: 2px;
	object-fit: cover;
}

.fixlight-alt-input {
	width: 100%;
	min-width: 220px;
}

.fixlight-image-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 6px;
}

/* A saved row: tinted, with its status as a badge. No opacity, so text keeps its contrast. */
.fixlight-images > tbody > tr.fixlight-row-done,
.fixlight-images .fixlight-row-done > td {
	background-color: #edfaef;
}

.fixlight-row-done .fixlight-row-status {
	display: inline-block;
	border: 1px solid #00a32a;
	border-radius: 10px;
	padding: 1px 8px;
	background: #fff;
	color: #005c12;
	font-weight: 600;
}

.fixlight-pagination {
	margin: 16px 0;
}

.fixlight-pagination .page-numbers {
	display: inline-block;
	padding: 4px 10px;
	margin-right: 4px;
	border: 1px solid #c3c4c7;
	border-radius: 3px;
	text-decoration: none;
}

.fixlight-pagination .current {
	background: #2271b1;
	border-color: #2271b1;
	color: #fff;
}

@media (max-width: 782px) {
	.fixlight-score-number {
		font-size: 36px;
	}

	.fixlight-stats {
		margin-left: 0;
		flex-basis: 100%;
	}

	/* Tables become one block per row, so nothing scrolls sideways. */
	.fixlight-stack thead {
		position: absolute;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip-path: inset(50%);
		white-space: nowrap;
	}

	.fixlight-stack,
	.fixlight-stack tbody,
	.fixlight-stack tr,
	.fixlight-stack td {
		display: block;
		width: auto;
	}

	.fixlight-stack td {
		overflow-wrap: anywhere;
	}

	.fixlight-stack .fixlight-image-cell {
		display: flex;
	}

	.fixlight-alt-input {
		min-width: 0;
	}
}

/* Reports screen: buttons next to each report. */
.fixlight-inline-form {
	display: inline-block;
	margin: 4px 8px 4px 0;
}

/* Two small actions side by side (the overlay card). */
.fixlight-inline-actions {
	display: inline-block;
	margin: 0 12px 0 0;
}
