/**
 * Game Center — front-end styles.
 * Uses the same design system as the Educational Game Dashboard (colours, rounded
 * system font, soft shadows, pill controls, tinted icon cards), so both plugins
 * look like one product. Scoped under .gc so the theme is never affected.
 *   .gc.gc-dash    [game_center_games]
 *   .gc.gc-family  [game_center_family]
 *   body.gc-page   pages served by the plugin (child picker, messages)
 */

.gc {
	--gc-ink: #1f2547;
	--gc-ink-soft: #5b628a;
	--gc-surface: #ffffff;
	--gc-canvas: #f6f4ff;
	--gc-line: #e4e1f5;
	--gc-brand: #5b4bdb;
	--gc-brand-ink: #ffffff;
	--gc-brand-soft: #ece9ff;
	--gc-play: #15a46b;
	--gc-play-soft: #e2f7ee;
	--gc-lock: #7a6fb3;
	--gc-lock-soft: #efedf8;
	--gc-sun: #ffc93c;
	--gc-coral: #ff7a6b;
	--gc-danger: #d63649;
	--gc-danger-soft: #fdecee;
	--gc-radius: 20px;
	--gc-radius-sm: 12px;
	--gc-shadow: 0 1px 2px rgba(31, 37, 71, .06), 0 6px 18px rgba(31, 37, 71, .08);
	--gc-shadow-lift: 0 2px 4px rgba(31, 37, 71, .08), 0 14px 30px rgba(31, 37, 71, .14);
	--gc-focus: 0 0 0 3px #fff, 0 0 0 6px #5b4bdb;
	--gc-icon-d: 300px;
	--gc-icon-t: 220px;
	--gc-mcols: 2;
	--gc-zoom: 1;
	--gc-gap: 20px;
	--gc-media-pad: 12px;

	color: var(--gc-ink);
	font-family: ui-rounded, "Nunito", "Quicksand", "Segoe UI Rounded", "Segoe UI", system-ui, -apple-system, sans-serif;
	font-size: 16px;
	line-height: 1.45;
	box-sizing: border-box;
	color-scheme: light;
}

/* border-box set directly: children of <details> are slotted and would not inherit it */
.gc *,
.gc *::before,
.gc *::after {
	box-sizing: border-box;
}

.gc :is(h1, h2, h3, h4, p, ul, ol, li, figure, fieldset) {
	margin: 0;
	padding: 0;
}

.gc :is(ul, ol) {
	list-style: none;
}

/* Neutralise common theme rules on lists, list items and links inside the dashboard.
   :where() keeps this low-specificity so the component styles below still win. */
.gc :where(ul, ol, li) {
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	box-shadow: none;
	list-style: none;
}

.gc :where(li)::before,
.gc :where(li)::after {
	content: none;
}

.gc :where(a) {
	color: inherit;
	box-shadow: none;
	border-bottom: 0;
}

/* The list items we style, at a specificity most theme list rules cannot beat. */
.gc .gc-grid > li,
.gc .gc-pagination__list > li,
.gc .gc-kid__stats > li {
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	box-shadow: none;
	list-style: none;
}

.gc .gc-grid > li::before,
.gc .gc-grid > li::after,
.gc .gc-pagination__list > li::before,
.gc .gc-kid__stats > li::before {
	content: none;
	display: none;
}

.gc a {
	text-decoration: none;
}

.gc-sr {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* ---------- Shell ---------- */
.gc-dash,
.gc-family {
	container: gcdash / inline-size;
	background: var(--gc-canvas);
	border-radius: calc(var(--gc-radius) + 8px);
	padding: clamp(16px, 3vw, 32px);
	width: 100%;
	max-width: 100%;
	overflow: hidden;
	margin-bottom: 32px;
}

.gc-header {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px 24px;
	margin-bottom: 20px;
}

.gc .gc-title {
	margin: 0;
	font-family: inherit;
	font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.25rem);
	font-weight: 800;
	letter-spacing: -0.01em;
	line-height: 1.15;
	color: var(--gc-ink);
}

.gc-welcome {
	margin: 6px 0 0 !important;
	color: var(--gc-ink-soft);
	font-size: 1rem;
}

.gc-link {
	color: var(--gc-brand);
	font-weight: 700;
}

.gc-notice {
	margin: 0 0 16px !important;
	padding: 12px 16px;
	border-radius: var(--gc-radius-sm);
	background: var(--gc-play-soft);
	color: #0d7a4e;
	font-weight: 700;
}

.gc-notice.is-error {
	background: var(--gc-danger-soft);
	color: #a3263a;
}

/* ---------- Controls ---------- */
.gc-controls {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	gap: 12px;
	margin: 0 0 12px;
}

.gc-search {
	position: relative;
	flex: 1 1 100%; /* own row; the dropdowns and zoom share the next one */
	min-width: 0;
}

.gc-search__icon {
	position: absolute;
	left: 16px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--gc-ink-soft);
	display: flex;
	pointer-events: none;
}

.gc .gc-input,
.gc .gc-select {
	width: 100%;
	min-height: 48px;
	margin: 0;
	padding: 0 16px;
	font: inherit;
	font-size: 1rem;
	color: var(--gc-ink);
	background-color: var(--gc-surface);
	border: 2px solid var(--gc-line);
	border-radius: 999px;
	box-shadow: none;
	transition: border-color .15s ease;
}

.gc .gc-input--search {
	padding-left: 46px;
}

.gc .gc-input--box {
	border-radius: var(--gc-radius-sm);
}

.gc .gc-select {
	appearance: none;
	-webkit-appearance: none;
	padding-right: 40px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%235b628a' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
	background-size: 22px;
	cursor: pointer;
}

.gc .gc-input:hover,
.gc .gc-select:hover {
	border-color: #cfc9f0;
}

.gc .gc-input:focus-visible,
.gc .gc-select:focus-visible {
	outline: none;
	border-color: var(--gc-brand);
	box-shadow: 0 0 0 4px rgba(91, 75, 219, .18);
}

.gc-filters {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	align-items: flex-end;
	flex: 999 1 520px;
	min-width: 0;
}

.gc-field {
	display: flex;
	flex-direction: column;
	gap: 4px;
	min-width: 185px;
	flex: 1 1 185px;
	margin: 0;
}

.gc-field--narrow {
	min-width: 96px;
	flex: 0 1 120px;
}

.gc-field__label {
	font-size: .8125rem;
	font-weight: 700;
	color: var(--gc-ink-soft);
	padding-left: 14px;
}

.gc-zoom {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 4px;
	background: var(--gc-surface);
	border: 2px solid var(--gc-line);
	border-radius: 999px;
	margin-left: auto;
}

.gc .gc-zoom__btn {
	width: 40px;
	height: 40px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: var(--gc-brand-soft);
	color: var(--gc-brand);
	font: inherit;
	font-size: 1.375rem;
	font-weight: 800;
	line-height: 1;
	cursor: pointer;
	box-shadow: none;
	transition: background-color .15s ease, transform .1s ease;
}

.gc .gc-zoom__btn:hover:not(:disabled) {
	background: #ddd8ff;
}

.gc .gc-zoom__btn:active:not(:disabled) {
	transform: scale(.94);
}

.gc .gc-zoom__btn:disabled {
	opacity: .4;
	cursor: not-allowed;
}

.gc-zoom__value {
	min-width: 52px;
	text-align: center;
	font-weight: 800;
	font-variant-numeric: tabular-nums;
}

.gc-summary {
	margin: 4px 0 16px !important;
	font-size: .9375rem;
	color: var(--gc-ink-soft);
}

.gc-actives {
	display: inline-flex;
	flex-wrap: wrap;
	gap: 6px;
	margin-left: 8px;
	vertical-align: middle;
}

.gc .gc-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 2px 10px;
	border-radius: 999px;
	background: var(--gc-brand-soft);
	color: var(--gc-brand);
	font-size: .8125rem;
	font-weight: 800;
}

/* ---------- Buttons ---------- */
.gc .gc-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 48px;
	margin: 0;
	padding: 0 22px;
	border: 2px solid var(--gc-line);
	border-radius: 999px;
	background: var(--gc-surface);
	color: var(--gc-ink);
	font: inherit;
	font-weight: 800;
	line-height: 1.1;
	text-decoration: none;
	white-space: nowrap;
	cursor: pointer;
	box-shadow: none;
	transition: transform .1s ease, background-color .15s ease, box-shadow .15s ease;
}

.gc .gc-btn:hover {
	transform: translateY(-1px);
	color: var(--gc-ink);
}

.gc .gc-btn--primary {
	background: var(--gc-brand);
	border-color: var(--gc-brand);
	color: var(--gc-brand-ink);
	box-shadow: 0 6px 16px rgba(91, 75, 219, .3);
}

.gc .gc-btn--primary:hover {
	background: #4c3dc7;
	color: #fff;
}

.gc .gc-btn--play {
	background: var(--gc-play);
	border-color: var(--gc-play);
	color: #fff;
	box-shadow: 0 6px 16px rgba(21, 164, 107, .28);
}

.gc .gc-btn--play:hover {
	background: #0f8f5c;
	color: #fff;
}

.gc .gc-btn--ghost {
	background: transparent;
	color: var(--gc-brand);
	border-color: #d4cff5;
}

.gc .gc-btn--danger {
	background: var(--gc-surface);
	border-color: #f3b9c1;
	color: var(--gc-danger);
}

.gc .gc-btn--sm {
	min-height: 40px;
	padding: 0 16px;
	font-size: .875rem;
}

.gc .gc-btn--block {
	width: 100%;
}

.gc .gc-btn:focus-visible,
.gc a:focus-visible,
.gc button:focus-visible,
.gc summary:focus-visible {
	outline: none;
	box-shadow: var(--gc-focus);
}

/* ---------- Grid (card width = icon size × zoom) ---------- */
.gc-grid {
	display: grid;
	gap: var(--gc-gap);
	justify-content: center;
	grid-template-columns: repeat(auto-fill, min(calc(var(--gc-icon-d) * var(--gc-zoom)), 100%));
}

@container gcdash (max-width: 899px) {
	.gc-grid {
		grid-template-columns: repeat(auto-fill, min(calc(var(--gc-icon-t) * var(--gc-zoom)), 100%));
	}
}

@container gcdash (max-width: 559px) {
	.gc-grid {
		--gc-gap: 12px;
		justify-content: stretch;
		grid-template-columns: repeat(auto-fill, minmax(min(calc(var(--gc-icon-t) * .64 * var(--gc-zoom)), calc((100% - (var(--gc-mcols) - 1) * 12px) / var(--gc-mcols))), 1fr));
	}
}

/* ---------- Square icon (1:1) with saved zoom and position ---------- */
.gc-icon {
	position: relative;
	display: block;
	width: 100%;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	border-radius: var(--gc-radius-sm, 12px);
	background: rgba(255, 255, 255, .5);
}

.gc-icon img {
	position: absolute !important;
	inset: 0;
	width: 100% !important;
	height: 100% !important;
	max-width: none !important;
	margin: 0 !important;
	border-radius: 0 !important;
	object-fit: cover;
	object-position: var(--gc-x, 50%) var(--gc-y, 50%);
	transform: scale(var(--gc-z, 1));
	transform-origin: var(--gc-x, 50%) var(--gc-y, 50%);
	transition: filter .25s ease;
}

.gc-icon-empty {
	display: flex;
	align-items: center;
	justify-content: center;
	background: transparent;
	font-size: clamp(2rem, 30cqi, 6rem);
	container-type: inline-size;
}

/* ---------- Card ---------- */
.gc-card {
	margin: 0;
	padding: 0;
	min-width: 0;
	container-type: inline-size;
	--gc-tint: #eef0ff;
	--gc-tint-ink: #5b4bdb;
}

.gc-card:nth-child(6n+2) { --gc-tint: #fff3d6; --gc-tint-ink: #b7791f; }
.gc-card:nth-child(6n+3) { --gc-tint: #e2f7ee; --gc-tint-ink: #15a46b; }
.gc-card:nth-child(6n+4) { --gc-tint: #ffe7e3; --gc-tint-ink: #e0523f; }
.gc-card:nth-child(6n+5) { --gc-tint: #e3f2ff; --gc-tint-ink: #2b7bd6; }
.gc-card:nth-child(6n+6) { --gc-tint: #f6e8ff; --gc-tint-ink: #9d4edd; }

.gc-card__hit {
	all: unset;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	width: 100%;
	height: 100%;
	background: var(--gc-surface);
	border-radius: var(--gc-radius);
	box-shadow: var(--gc-shadow);
	overflow: hidden;
	cursor: pointer;
	color: var(--gc-ink);
	text-align: left;
	text-decoration: none;
	transition: transform .18s ease, box-shadow .18s ease;
	-webkit-tap-highlight-color: transparent;
}

.gc-card__hit:hover {
	transform: translateY(-3px);
	box-shadow: var(--gc-shadow-lift);
	color: var(--gc-ink);
}

.gc-card__hit:active {
	transform: translateY(0) scale(.985);
}

.gc .gc-card__hit:focus-visible {
	box-shadow: var(--gc-focus), var(--gc-shadow-lift);
}

.gc-card__media {
	position: relative;
	display: block;
	aspect-ratio: 1 / 1;
	background: var(--gc-tint);
	padding: var(--gc-media-pad);
}

.gc-card--unlocked .gc-card__hit:hover .gc-icon img {
	filter: brightness(1.04);
}

.gc-card--locked .gc-icon img,
.gc-card--guest .gc-icon img {
	filter: saturate(.55);
}

.gc-card__overlay {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: linear-gradient(180deg, rgba(255, 255, 255, .15), rgba(48, 40, 110, .32));
}

.gc-card__padlock {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 52px;
	height: 52px;
	border-radius: 999px;
	background: rgba(255, 255, 255, .95);
	color: var(--gc-lock);
	box-shadow: 0 4px 14px rgba(31, 37, 71, .2);
	transition: transform .18s ease;
}

.gc-card__hit:hover .gc-card__padlock {
	transform: scale(1.08) rotate(-6deg);
}

.gc-card__badges {
	position: absolute;
	top: 8px;
	left: 8px;
	right: 8px;
	display: flex;
	flex-wrap: wrap;
	gap: 4px;
	pointer-events: none;
}

.gc-badge {
	display: inline-block;
	padding: 2px 9px;
	border-radius: 999px;
	font-size: .6875rem;
	font-weight: 800;
	letter-spacing: .02em;
	text-transform: uppercase;
	line-height: 1.6;
	color: #fff;
	background: var(--gc-brand);
	box-shadow: 0 2px 6px rgba(31, 37, 71, .18);
}

.gc-badge--new { background: var(--gc-coral); }
.gc-badge--popular { background: var(--gc-play); }

.gc-card__body {
	display: flex;
	flex-direction: column;
	gap: 4px;
	flex: 1;
	padding: 12px 14px 14px;
}

.gc-card__title {
	font-size: calc(.95rem + .1rem * var(--gc-zoom));
	font-weight: 800;
	line-height: 1.25;
	overflow-wrap: anywhere;
}

.gc-card__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 4px 8px;
	font-size: .8125rem;
	color: var(--gc-ink-soft);
}

.gc-card__cat {
	color: var(--gc-tint-ink);
	font-weight: 700;
}

.gc-card__meta > * + *::before {
	content: "·";
	margin-right: 8px;
	color: #c9c4e8;
}

.gc-card__desc {
	font-size: .875rem;
	line-height: 1.4;
	color: var(--gc-ink-soft);
	display: -webkit-box;
	-webkit-line-clamp: 2;
	line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	overflow-wrap: anywhere;
}

@container (min-width: 320px) {
	.gc-card__desc {
		-webkit-line-clamp: 3;
		line-clamp: 3;
	}
}

@container (max-width: 120px) {
	.gc-card__desc {
		display: none;
	}
}

.gc-card__status {
	display: inline-flex;
	align-items: center;
	align-self: flex-start;
	gap: 6px;
	margin-top: auto;
	padding: 6px 12px;
	border-radius: 999px;
	font-size: .8125rem;
	font-weight: 800;
	letter-spacing: .03em;
	text-transform: uppercase;
	transform: translateY(4px);
}

.gc-card__status svg {
	flex: none;
}

.gc-card--unlocked .gc-card__status {
	background: var(--gc-play-soft);
	color: #0d7a4e;
}

.gc-card--locked .gc-card__status,
.gc-card--guest .gc-card__status {
	background: var(--gc-lock-soft);
	color: var(--gc-lock);
}

.gc-meter {
	display: block;
	height: 8px;
	margin-top: 4px;
	border-radius: 999px;
	background: var(--gc-line);
	overflow: hidden;
}

.gc-meter > i {
	display: block;
	height: 100%;
	border-radius: inherit;
	background: var(--gc-play);
}

/* very small cards (phone, zoomed out): keep everything inside the card */
@container (max-width: 150px) {
	.gc-badge + .gc-badge,
	.gc-card__meta > :not(:first-child) {
		display: none;
	}
	.gc-card__badges {
		top: 6px;
		left: 6px;
	}
	.gc-badge {
		padding: 1px 7px;
		font-size: .625rem;
	}
	.gc-card__padlock {
		width: 40px;
		height: 40px;
	}
	.gc-card__body {
		padding: 8px 10px 10px;
	}
	.gc-card__title {
		font-size: .875rem;
		overflow-wrap: break-word;
		hyphens: auto;
	}
	.gc-card__status {
		padding: 5px 9px;
		font-size: .75rem;
		letter-spacing: 0;
		text-transform: none;
		max-width: 100%;
		overflow: hidden;
		white-space: nowrap;
		text-overflow: ellipsis;
	}
	.gc-card__status svg {
		display: none;
	}
}

/* ---------- Empty state ---------- */
.gc-empty {
	text-align: center;
	padding: 48px 16px;
	background: var(--gc-surface);
	border-radius: var(--gc-radius);
	color: var(--gc-ink-soft);
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
}

.gc-empty__icon {
	font-size: 2.5rem;
	line-height: 1;
}

.gc-empty__title {
	font-size: 1.25rem;
	font-weight: 800;
	color: var(--gc-ink);
}

/* ---------- Pagination ---------- */
.gc-pagination {
	margin-top: 28px;
}

.gc-pagination__list {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 8px;
}

.gc .gc-page {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 44px;
	min-height: 44px;
	padding: 0 14px;
	border-radius: 999px;
	background: var(--gc-surface);
	border: 2px solid var(--gc-line);
	color: var(--gc-ink);
	font-weight: 800;
	font-variant-numeric: tabular-nums;
	text-decoration: none;
	transition: background-color .15s ease, border-color .15s ease;
}

.gc a.gc-page:hover {
	border-color: var(--gc-brand);
	color: var(--gc-brand);
}

.gc .gc-page.is-current {
	background: var(--gc-brand);
	border-color: var(--gc-brand);
	color: #fff;
}

.gc .gc-page--gap {
	border-color: transparent;
	background: transparent;
	min-width: 24px;
	padding: 0;
}

/* ---------- Lock modal ---------- */
html.gc-modal-open {
	overflow: hidden;
}

.gc-modal {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
}

.gc-modal[hidden] {
	display: none;
}

.gc-modal__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(24, 20, 66, .55);
	animation: gc-fade .2s ease;
}

.gc-modal__dialog {
	position: relative;
	width: min(420px, 100%);
	max-height: calc(100vh - 32px);
	overflow: auto;
	padding: 32px 24px 24px;
	background: var(--gc-surface);
	border-radius: 28px;
	box-shadow: 0 24px 60px rgba(24, 20, 66, .35);
	text-align: center;
	animation: gc-pop .25s cubic-bezier(.2, .9, .3, 1.25);
}

.gc .gc-modal__close {
	position: absolute;
	top: 12px;
	right: 12px;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: var(--gc-canvas);
	color: var(--gc-ink-soft);
	font-size: 1.5rem;
	line-height: 1;
	cursor: pointer;
}

.gc-modal__lock {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 76px;
	height: 76px;
	margin-bottom: 8px;
	border-radius: 999px;
	background: var(--gc-brand-soft);
	color: var(--gc-brand);
}

.gc-modal__game {
	font-size: .875rem;
	font-weight: 700;
	color: var(--gc-ink-soft);
}

.gc .gc-modal__title {
	margin: 4px 0 8px;
	font-family: inherit;
	font-size: 1.5rem;
	font-weight: 800;
	color: var(--gc-ink);
}

.gc-modal__actions {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin-top: 20px;
}

@keyframes gc-fade {
	from { opacity: 0; }
}

@keyframes gc-pop {
	from { opacity: 0; transform: translateY(12px) scale(.96); }
}

/* ---------- Family page ---------- */
.gc-kids {
	display: flex;
	flex-direction: column;
	gap: 20px;
}

.gc-kid {
	background: var(--gc-surface);
	border-radius: var(--gc-radius);
	box-shadow: var(--gc-shadow);
	padding: clamp(16px, 2.5vw, 24px);
	display: flex;
	flex-direction: column;
	gap: 16px;
	--gc-icon-d: 170px;
	--gc-icon-t: 150px;
	--gc-media-pad: 10px;
	--gc-zoom: 1;
}

.gc-kid:nth-child(5n+1) { --gc-kid-tint: #eef0ff; }
.gc-kid:nth-child(5n+2) { --gc-kid-tint: #fff3d6; }
.gc-kid:nth-child(5n+3) { --gc-kid-tint: #e2f7ee; }
.gc-kid:nth-child(5n+4) { --gc-kid-tint: #ffe7e3; }
.gc-kid:nth-child(5n+5) { --gc-kid-tint: #e3f2ff; }

.gc-kid__head {
	display: flex;
	align-items: center;
	gap: 16px;
}

.gc-kid__avatar {
	flex: none;
	width: 72px;
	height: 72px;
	border-radius: 999px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 2.5rem;
	line-height: 1;
	background: var(--gc-kid-tint, var(--gc-brand-soft));
}

.gc .gc-kid__name {
	font-family: inherit;
	font-size: 1.5rem;
	font-weight: 800;
	line-height: 1.2;
	color: var(--gc-ink);
}

.gc-kid__stats {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin-top: 6px !important;
}

.gc .gc-kid__stats > .gc-stat {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 3px 10px;
	border-radius: 999px;
	background: var(--gc-canvas);
	color: var(--gc-ink-soft);
	font-size: .8125rem;
	font-weight: 800;
}

.gc-stat svg {
	color: var(--gc-brand);
}

.gc .gc-kid__subtitle {
	font-family: inherit;
	font-size: 1rem;
	font-weight: 800;
	color: var(--gc-ink-soft);
}

.gc-kid .gc-grid {
	justify-content: start;
}

.gc-kid__empty {
	padding: 14px 16px;
	border-radius: var(--gc-radius-sm);
	background: var(--gc-canvas);
	color: var(--gc-ink-soft);
	font-weight: 700;
}

.gc-manage {
	border-top: 2px solid var(--gc-line);
	padding-top: 12px;
}

.gc-manage > summary {
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 40px;
	padding: 0 14px;
	border-radius: 999px;
	font-weight: 800;
	color: var(--gc-brand);
	background: var(--gc-brand-soft);
	list-style: none;
}

.gc-manage > summary::-webkit-details-marker {
	display: none;
}

.gc-manage__body {
	display: grid;
	gap: 16px;
	grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
	margin-top: 14px;
}

.gc-panel {
	padding: 16px;
	border-radius: var(--gc-radius);
	background: var(--gc-canvas);
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.gc-panel--danger {
	background: var(--gc-danger-soft);
}

.gc .gc-panel__title {
	font-family: inherit;
	font-size: 1rem;
	font-weight: 800;
	color: var(--gc-ink);
}

.gc-panel__text {
	font-size: .875rem;
	color: var(--gc-ink-soft);
}

.gc-label {
	display: flex;
	flex-direction: column;
	gap: 4px;
	font-size: .8125rem;
	font-weight: 700;
	color: var(--gc-ink-soft);
}

.gc-label > span {
	padding-left: 14px;
}

.gc-add {
	border: 2px dashed #d4cff5;
	box-shadow: none;
	background: rgba(255, 255, 255, .6);
}

.gc-add .gc-kid__avatar {
	background: var(--gc-brand-soft);
	color: var(--gc-brand);
	font-weight: 800;
	font-size: 2rem;
}

/* avatar picker */
.gc-avatars {
	border: 0;
	padding: 0;
	margin: 0;
	min-width: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.gc-avatars legend {
	float: left;
	width: 100%;
	margin-bottom: 4px;
	padding-left: 14px;
	font-size: .8125rem;
	font-weight: 700;
	color: var(--gc-ink-soft);
}

.gc-avatars label {
	position: relative;
	display: inline-flex;
}

.gc-avatars input {
	position: absolute;
	opacity: 0;
	width: 1px;
	height: 1px;
}

.gc-avatars span {
	width: 48px;
	height: 48px;
	border-radius: 999px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.625rem;
	background: var(--gc-surface);
	border: 2px solid var(--gc-line);
	cursor: pointer;
	transition: transform .1s ease, border-color .15s ease;
}

.gc-avatars input:checked + span {
	border-color: var(--gc-brand);
	background: var(--gc-brand-soft);
	transform: scale(1.06);
}

.gc-avatars input:focus-visible + span {
	box-shadow: var(--gc-focus);
}

/* ---------- Pages served by the plugin (child picker, messages) ---------- */
body.gc-page {
	margin: 0;
	min-height: 100vh;
	padding: clamp(16px, 4vw, 48px) 16px;
	background: var(--gc-canvas);
}

.gc-sheet {
	max-width: 720px;
	margin: 0 auto;
	padding: clamp(20px, 4vw, 32px);
	background: var(--gc-surface);
	border-radius: 28px;
	box-shadow: var(--gc-shadow);
	display: flex;
	flex-direction: column;
	gap: 20px;
}

.gc-sheet--center {
	max-width: 480px;
	margin-top: clamp(24px, 8vh, 80px);
	text-align: center;
	align-items: center;
}

.gc-sheet__lock {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 76px;
	height: 76px;
	border-radius: 999px;
	background: var(--gc-brand-soft);
	color: var(--gc-brand);
}

.gc-sheet__head {
	display: flex;
	align-items: center;
	gap: 16px;
}

.gc-sheet__icon {
	flex: none;
	width: 72px;
	padding: 6px;
	border-radius: 18px;
	background: var(--gc-brand-soft);
}

.gc-sheet__icon .gc-icon {
	border-radius: 12px;
}

.gc-sheet__kicker {
	font-size: .875rem;
	font-weight: 700;
	color: var(--gc-ink-soft);
}

.gc-sheet__text {
	color: var(--gc-ink-soft);
}

.gc-sheet__foot {
	font-size: .875rem;
	color: var(--gc-ink-soft);
}

.gc-sheet__foot a {
	color: var(--gc-brand);
	font-weight: 700;
}

.gc-who {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(150px, 100%), 1fr));
	gap: 14px;
}

.gc .gc-who__item {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	padding: 20px 12px;
	background: var(--gc-surface);
	border-radius: var(--gc-radius);
	box-shadow: var(--gc-shadow);
	color: var(--gc-ink);
	font-weight: 800;
	font-size: 1.125rem;
	text-align: center;
	transition: transform .18s ease, box-shadow .18s ease;
}

.gc .gc-who__item:hover {
	transform: translateY(-3px);
	box-shadow: var(--gc-shadow-lift);
}

.gc-who__item:nth-child(5n+1) { --gc-kid-tint: #eef0ff; }
.gc-who__item:nth-child(5n+2) { --gc-kid-tint: #fff3d6; }
.gc-who__item:nth-child(5n+3) { --gc-kid-tint: #e2f7ee; }
.gc-who__item:nth-child(5n+4) { --gc-kid-tint: #ffe7e3; }
.gc-who__item:nth-child(5n+5) { --gc-kid-tint: #e3f2ff; }

.gc-who__add {
	border-top: 2px solid var(--gc-line);
	padding-top: 16px;
}

.gc-who__add > summary {
	cursor: pointer;
	font-weight: 800;
	color: var(--gc-brand);
}

.gc-who__add form {
	display: flex;
	flex-direction: column;
	gap: 12px;
	margin-top: 12px;
}

/* ---------- Responsive ---------- */
@container gcdash (max-width: 899px) {
	.gc-filters {
		flex-basis: 100%;
	}
	.gc-field,
	.gc-field--narrow {
		flex: 1 1 calc(50% - 6px);
		min-width: 0;
	}
}

@container gcdash (max-width: 700px) {
	.gc-zoom {
		margin-left: 0;
	}
	.gc-filters {
		flex-basis: 100%;
	}
}

@container gcdash (max-width: 559px) {
	.gc-field,
	.gc-field--narrow {
		flex: 1 1 calc(50% - 6px);
		min-width: 0;
	}
	.gc-card__body {
		padding: 10px 12px 12px;
	}
	.gc-pagination .gc-page--prev,
	.gc-pagination .gc-page--next {
		flex: 1;
	}
	.gc-kid__avatar {
		width: 60px;
		height: 60px;
		font-size: 2rem;
	}
}

@media (max-width: 700px) {
	.gc-dash,
	.gc-family {
		border-radius: var(--gc-radius);
		padding: 16px 12px;
	}
}

@media (hover: none) {
	.gc-card__hit:hover {
		transform: none;
		box-shadow: var(--gc-shadow);
	}
}

@media (prefers-reduced-motion: reduce) {
	.gc *,
	.gc *::before,
	.gc *::after {
		animation: none !important;
		transition: none !important;
	}
}

@media (forced-colors: active) {
	.gc-card__hit,
	.gc-btn,
	.gc-page {
		border: 2px solid CanvasText;
	}
}
