/* Game Tools — checklist ([game_checklist]). Loaded only on pages that use the shortcode.
 * Tokens, the sticky bar, form controls, pills and buttons are in base.css. */

/* ---------- Progress (overall + per section) ---------- */

.gt-progress-head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
}

.gt-progress-label {
	font-size: 14px;
	font-weight: 700;
}

.gt-count {
	flex: none;
	font-size: 14px;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	color: var( --gt-muted );
}

.gt-track {
	display: block;
	height: 8px;
	margin-top: 8px;
	overflow: hidden;
	background: var( --gt-panel2 );
	border: 1px solid var( --gt-line );
	border-radius: 999px;
}

.gt-fill {
	display: block;
	width: 0;
	height: 100%;
	background: var( --gt-blue );
	border-radius: 999px;
	transition: width 0.2s ease;
}

.gt-overall {
	margin: 0 0 12px;
}

/* ---------- Sections and items ---------- */

.gt-section-head {
	margin: 16px 0 4px;
}

.gt-checklist .gt-items {
	margin: 0;
	padding: 0;
	list-style: none;
}

.gt-checklist .gt-item {
	margin: 0;
	padding: 0;
	border-bottom: 1px solid var( --gt-line );
}

/* The whole row is the tap target. */
.gt-row {
	display: flex;
	align-items: flex-start;
	gap: 14px;
	min-height: 56px;
	margin: 0;
	padding: 14px 4px;
	cursor: pointer;
	-webkit-tap-highlight-color: transparent;
}

.gt-row:active {
	background: var( --gt-panel2 );
}

.gt-checklist .gt-check {
	flex: none;
	width: 26px;
	height: 26px;
	margin: 1px 0 0;
	accent-color: var( --gt-btn );
	cursor: pointer;
}

.gt-body {
	display: flex;
	flex-direction: column;
	gap: 3px;
	min-width: 0;
}

.gt-title {
	font-size: 16px;
	font-weight: 600;
	line-height: 1.35;
	overflow-wrap: anywhere;
}

.gt-desc {
	font-size: 14px;
	line-height: 1.45;
	color: var( --gt-muted );
	overflow-wrap: anywhere;
}

.gt-meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
	margin-top: 3px;
	font-size: 13px;
	line-height: 1.5;
	color: var( --gt-muted );
}

.gt-loc::before {
	content: '';
	display: inline-block;
	width: 12px;
	height: 12px;
	margin-right: 4px;
	vertical-align: -1px;
	background: currentColor;
	-webkit-mask: var( --gt-icon-pin ) center / contain no-repeat;
	mask: var( --gt-icon-pin ) center / contain no-repeat;
}

.gt-checklist {
	--gt-icon-pin: url( "data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 22s7-6.2 7-12a7 7 0 0 0-14 0c0 5.8 7 12 7 12z'/%3E%3Ccircle cx='12' cy='10' r='2.5'/%3E%3C/svg%3E" );
}

.gt-item.is-done .gt-title {
	text-decoration: line-through;
	color: var( --gt-muted );
}

/* ---------- Reset ---------- */

.gt-reset {
	flex: 0 1 auto;
	min-width: 0;
}

.gt-checklist .gt-btn-danger,
.gt-checklist .gt-btn-danger:hover,
.gt-checklist .gt-btn-danger:focus {
	color: #fff;
	background: var( --gt-danger );
	border-color: var( --gt-danger );
}

.gt-confirm {
	padding: 12px;
	background: var( --gt-panel2 );
	border: 1px solid var( --gt-line );
	border-radius: var( --gt-radius );
}

.gt-checklist .gt-confirm-text {
	margin: 0 0 10px;
	font-size: 15px;
	font-weight: 600;
}

.gt-confirm-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.gt-confirm .gt-btn:not( .gt-btn-danger ) {
	background: var( --gt-panel );
}

@media ( prefers-reduced-motion: reduce ) {
	.gt-fill {
		transition: none;
	}
}
