/**
 * Inoforest Social Stats
 *
 * Contents
 * 1. Grid (variables)
 * 2. Card and inline
 * 3. Icon, number, label, handle
 * 4. Editor hint, reduced motion
 *
 * Colours read the Design System (--inoforest-color-*) with fallbacks. Style-tab controls target the parts with three
 * classes, one more than the rules here, so a choice in the panel always wins.
 */

/* 1. Grid ------------------------------------------------------------------ */
.inoforest-social-stats {
	--ino-ss-columns: 2;
	--ino-ss-gap: 16px;
	--ino-ss-primary: var(--inoforest-color-primary, #0b7a75);
}

.inoforest-social-stats .inoforest-social-stats__list {
	display: grid;
	grid-template-columns: repeat(var(--ino-ss-columns), minmax(0, 1fr));
	gap: var(--ino-ss-row-gap, var(--ino-ss-gap)) var(--ino-ss-gap);
	margin: 0;
	padding: 0;
	list-style: none;
}

.inoforest-social-stats__item {
	min-width: 0;
	margin: 0;
	padding: 0;
}

/* 2. Card and inline ---------------------------------------------------------- */
.inoforest-social-stats .inoforest-social-stats__card {
	display: flex;
	align-items: center;
	gap: 14px;
	height: 100%;
	padding: 18px 20px;
	color: inherit;
	text-decoration: none;
	background-color: var(--inoforest-color-background, #fff);
	border: 1px solid var(--inoforest-color-border, #e3e9ee);
	border-radius: 16px;
	transition: border-color 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
}

.inoforest-social-stats a.inoforest-social-stats__card:hover,
.inoforest-social-stats a.inoforest-social-stats__card:focus-visible {
	color: inherit;
	border-color: var(--ino-ss-primary);
	box-shadow: 0 6px 20px rgba(13, 27, 42, 0.08);
}

.inoforest-social-stats:where([data-style="inline"]) .inoforest-social-stats__card {
	padding: 0;
	background-color: transparent;
	border-width: 0;
}

.inoforest-social-stats:where([data-style="inline"]) a.inoforest-social-stats__card:hover,
.inoforest-social-stats:where([data-style="inline"]) a.inoforest-social-stats__card:focus-visible {
	box-shadow: none;
}

/* 3. Icon, number, label, handle --------------------------------------------- */
.inoforest-social-stats .inoforest-social-stats__icon {
	display: grid;
	flex: none;
	place-items: center;
	width: 48px;
	height: 48px;
	font-size: 22px;
	line-height: 1;
	color: var(--ino-ss-primary);
	background-color: color-mix(in srgb, var(--ino-ss-primary) 12%, #fff);
	border-radius: 50%;
}

.inoforest-social-stats__icon svg {
	width: 1em;
	height: 1em;
	fill: currentColor;
}

.inoforest-social-stats__body {
	min-width: 0;
}

.inoforest-social-stats .inoforest-social-stats__number {
	display: block;
	font-family: var(--inoforest-font-heading-family, inherit);
	font-size: 1.6rem;
	font-weight: 600;
	line-height: 1.1;
	color: var(--inoforest-color-heading, #0d1b2a);
}

.inoforest-social-stats .inoforest-social-stats__label {
	display: block;
	font-size: 0.85rem;
	color: var(--inoforest-color-text, #5a6a79);
}

.inoforest-social-stats .inoforest-social-stats__handle {
	display: block;
	font-size: 0.8rem;
	font-weight: 700;
	color: var(--ino-ss-primary);
	overflow-wrap: anywhere;
}

/* 4. Editor hint, reduced motion ------------------------------------------------ */
.inoforest-social-stats__hint {
	margin: 0;
	font-size: 0.85rem;
}

@media (prefers-reduced-motion: reduce) {
	.inoforest-social-stats .inoforest-social-stats__card {
		transition: none;
	}
}
