/* Shared game-library cards for Home and Games pages. */

.games-page-header,
.games-section-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 18px;
	padding: 18px 20px;
	border: 1px solid rgba(33, 37, 41, 0.08);
	border-radius: 10px;
	background: #ffffff;
	box-shadow: 0 8px 28px rgba(18, 38, 63, 0.06);
}

.games-page-header h1,
.games-section-header h2 {
	margin: 2px 0 0;
	color: #1f2937;
	font-size: 24px;
	font-weight: 800;
	line-height: 1.2;
}

.games-section-header__eyebrow {
	display: block;
	color: #6b7280;
	font-size: 11px;
	font-weight: 800;
	letter-spacing: 0;
	text-transform: uppercase;
}

.games-page-header__count,
.games-section-header__link {
	flex: 0 0 auto;
	border-radius: 999px;
	padding: 8px 13px;
	background: #f4f7fb;
	color: #475569;
	font-size: 12px;
	font-weight: 700;
	text-decoration: none;
}

.games-section-header__link:hover,
.games-section-header__link:focus {
	color: #0f62fe;
	text-decoration: none;
}

.games-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(176px, 1fr));
	gap: 18px;
}

.games-grid--featured {
	grid-template-columns: repeat(auto-fill, minmax(176px, 1fr));
}

.game-card {
	position: relative;
	display: flex;
	flex-direction: column;
	min-height: 222px;
	overflow: hidden;
	border: 1px solid rgba(15, 23, 42, 0.08);
	border-radius: 10px;
	background: #ffffff;
	color: inherit;
	text-decoration: none;
	box-shadow: 0 8px 26px rgba(15, 23, 42, 0.06);
	transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.game-card:hover,
.game-card:focus-within,
.game-card:active {
	border-color: rgba(15, 98, 254, 0.28);
	box-shadow: 0 16px 42px rgba(15, 23, 42, 0.14);
	text-decoration: none;
	transform: translateY(-3px);
}

.game-card__media {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	height: 148px;
	background:
		linear-gradient(135deg, rgba(15, 98, 254, 0.08), rgba(0, 196, 159, 0.08)),
		#f8fafc;
}

.game-card__media::after {
	content: '';
	position: absolute;
	inset: 0;
	background: rgba(15, 23, 42, 0);
	transition: background 0.2s ease;
}

.game-card:hover .game-card__media::after,
.game-card:focus-within .game-card__media::after,
.game-card:active .game-card__media::after {
	background: rgba(15, 23, 42, 0.46);
}

.game-card__image {
	width: 76%;
	height: 76%;
	object-fit: contain;
	filter: drop-shadow(0 12px 20px rgba(15, 23, 42, 0.16));
	transition: transform 0.2s ease;
}

.game-card:hover .game-card__image,
.game-card:focus-within .game-card__image,
.game-card:active .game-card__image {
	transform: scale(1.04);
}

.game-card__play {
	position: absolute;
	z-index: 2;
	top: 50%;
	left: 50%;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	min-width: 86px;
	height: 38px;
	padding: 0 14px;
	border-radius: 999px;
	background: #ffffff;
	color: #111827;
	font-size: 13px;
	font-weight: 800;
	box-shadow: 0 12px 32px rgba(0, 0, 0, 0.22);
	opacity: 0;
	transform: translate(-50%, -44%) scale(0.94);
	transition: opacity 0.2s ease, transform 0.2s ease;
}

.game-card__play svg {
	width: 15px;
	height: 15px;
	margin-left: 1px;
}

.game-card:hover .game-card__play,
.game-card:focus-within .game-card__play,
.game-card:active .game-card__play,
.game-card.is-touch-active .game-card__play {
	opacity: 1;
	transform: translate(-50%, -50%) scale(1);
}

.game-card__body {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	justify-content: center;
	gap: 4px;
	padding: 13px 14px 15px;
	text-align: center;
}

.game-card__title {
	color: #111827;
	font-size: 15px;
	font-weight: 800;
	line-height: 1.25;
}

.game-card__meta {
	color: #64748b;
	font-size: 11px;
	font-weight: 700;
	line-height: 1.25;
}

@media (max-width: 767px) {
	.games-page-header,
	.games-section-header {
		align-items: flex-start;
		flex-direction: column;
		padding: 16px;
	}

	.games-grid,
	.games-grid--featured {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 14px;
	}

	.game-card {
		min-height: 198px;
	}

	.game-card__media {
		height: 128px;
	}
}

@media (max-width: 420px) {
	.games-grid,
	.games-grid--featured {
		grid-template-columns: 1fr;
	}
}

.public-page-hero {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 18px;
	margin-bottom: 18px;
	padding: 22px 24px;
	border: 1px solid rgba(15, 23, 42, 0.08);
	border-radius: 10px;
	background: #ffffff;
	box-shadow: 0 12px 34px rgba(15, 23, 42, 0.07);
}

.public-page-hero--refer {
	background:
		linear-gradient(135deg, rgba(14, 165, 233, 0.1), rgba(34, 197, 94, 0.09)),
		#ffffff;
}

.public-page-hero--points {
	background:
		linear-gradient(135deg, rgba(15, 98, 254, 0.08), rgba(245, 158, 11, 0.1)),
		#ffffff;
}

.public-page-hero h2 {
	margin: 2px 0 8px;
	color: #111827;
	font-size: 28px;
	font-weight: 900;
	line-height: 1.15;
}

.public-page-hero p {
	max-width: 760px;
	margin: 0;
	color: #475569;
	font-size: 14px;
	line-height: 1.6;
}

.public-page-hero__stat {
	display: flex;
	flex: 0 0 auto;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	min-width: 132px;
	min-height: 92px;
	padding: 16px;
	border: 1px solid rgba(15, 23, 42, 0.08);
	border-radius: 8px;
	background: rgba(255, 255, 255, 0.78);
	text-align: center;
}

.public-page-hero__stat span {
	color: #111827;
	font-size: 30px;
	font-weight: 900;
	line-height: 1;
}

.public-page-hero__stat small {
	margin-top: 8px;
	color: #64748b;
	font-size: 11px;
	font-weight: 800;
	text-transform: uppercase;
}

.refer-rewards-grid,
.point-system-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	gap: 18px;
	margin-bottom: 18px;
}

.refer-card,
.point-system-card,
.public-section-title,
.referral-user-card,
.public-empty-state {
	border: 1px solid rgba(15, 23, 42, 0.08);
	border-radius: 10px;
	background: #ffffff;
	box-shadow: 0 8px 26px rgba(15, 23, 42, 0.06);
}

.refer-card,
.point-system-card {
	display: flex;
	flex-direction: column;
	min-height: 198px;
	padding: 20px;
}

.refer-card__label,
.point-system-card__label {
	color: #0f62fe;
	font-size: 10px;
	font-weight: 900;
	letter-spacing: 0;
	text-transform: uppercase;
}

.refer-card h3,
.point-system-card h3 {
	margin: 8px 0;
	color: #111827;
	font-size: 22px;
	font-weight: 900;
	line-height: 1.2;
}

.refer-card p,
.point-system-card p {
	color: #64748b;
	font-size: 13px;
	line-height: 1.55;
}

.refer-card--image {
	min-height: 198px;
	overflow: hidden;
	padding: 0;
}

.refer-card--image img {
	width: 100%;
	height: 100%;
	min-height: 198px;
	object-fit: cover;
}

.refer-code {
	display: flex;
	gap: 10px;
	margin-top: auto;
}

.refer-code input {
	width: 100%;
	min-width: 0;
	height: 38px;
	padding: 0 12px;
	border: 1px solid rgba(15, 23, 42, 0.12);
	border-radius: 8px;
	background: #f8fafc;
	color: #111827;
	font-weight: 800;
}

.public-section-title {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 18px;
	padding: 18px 20px;
}

.public-section-title h3 {
	margin: 2px 0 0;
	color: #111827;
	font-size: 21px;
	font-weight: 900;
}

.public-section-title > span {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	height: 40px;
	border-radius: 50%;
	background: #0f62fe;
	color: #ffffff;
	font-weight: 900;
}

.referral-users-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
	gap: 18px;
}

.referral-users-grid--empty {
	grid-template-columns: 1fr;
}

.referral-user-card {
	display: grid;
	grid-template-columns: 72px minmax(0, 1fr);
	gap: 14px;
	padding: 16px;
}

.referral-user-card img {
	width: 72px;
	height: 72px;
	border-radius: 50%;
	object-fit: cover;
}

.referral-user-card h4 {
	margin: 2px 0 6px;
	color: #111827;
	font-size: 16px;
	font-weight: 850;
}

.referral-user-card p,
.referral-user-card small {
	display: block;
	margin: 0 0 8px;
	color: #64748b;
	font-size: 12px;
}

.public-empty-state {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	min-height: 220px;
	padding: 28px;
	text-align: center;
}

.public-empty-state > span {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 52px;
	height: 52px;
	margin-bottom: 12px;
	border-radius: 50%;
	background: #eff6ff;
	color: #0f62fe;
	font-size: 20px;
}

.public-empty-state h3 {
	margin: 0 0 8px;
	color: #111827;
	font-size: 20px;
	font-weight: 900;
}

.public-empty-state p {
	max-width: 420px;
	margin: 0;
	color: #64748b;
	font-size: 13px;
	line-height: 1.55;
}

.point-system-card {
	position: relative;
	overflow: hidden;
}

.point-system-card__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 48px;
	height: 48px;
	margin-bottom: 14px;
	border-radius: 50%;
	font-size: 18px;
}

.point-system-card__icon--blue,
.point-system-card__icon--indigo {
	background: #eff6ff;
	color: #0f62fe;
}

.point-system-card__icon--green,
.point-system-card__icon--teal {
	background: #ecfdf5;
	color: #059669;
}

.point-system-card__icon--purple {
	background: #f5f3ff;
	color: #7c3aed;
}

.point-system-card__icon--orange {
	background: #fff7ed;
	color: #ea580c;
}

.point-system-card__icon--grey {
	background: #f1f5f9;
	color: #475569;
}

.point-system-card__footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-top: auto;
	padding-top: 16px;
}

.point-system-card__footer > span {
	color: #111827;
	font-size: 12px;
	font-weight: 850;
}

.howto-hero {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 18px;
	margin-bottom: 18px;
	padding: 22px 24px;
	border: 1px solid rgba(15, 23, 42, 0.08);
	border-radius: 10px;
	background:
		linear-gradient(135deg, rgba(15, 98, 254, 0.08), rgba(0, 196, 159, 0.08)),
		#ffffff;
	box-shadow: 0 12px 34px rgba(15, 23, 42, 0.07);
}

.howto-hero h2 {
	margin: 2px 0 8px;
	color: #111827;
	font-size: 28px;
	font-weight: 900;
	line-height: 1.15;
}

.howto-hero p {
	max-width: 760px;
	margin: 0;
	color: #475569;
	font-size: 14px;
	line-height: 1.6;
}

.howto-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
	gap: 18px;
}

.howto-card {
	display: grid;
	grid-template-columns: 96px minmax(0, 1fr);
	min-height: 172px;
	overflow: hidden;
	border: 1px solid rgba(15, 23, 42, 0.08);
	border-radius: 10px;
	background: #ffffff;
	box-shadow: 0 8px 26px rgba(15, 23, 42, 0.06);
	transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.howto-card:hover,
.howto-card:focus-within {
	border-color: rgba(15, 98, 254, 0.24);
	box-shadow: 0 16px 42px rgba(15, 23, 42, 0.13);
	transform: translateY(-2px);
}

.howto-card__media {
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 14px;
	background:
		linear-gradient(135deg, rgba(15, 98, 254, 0.08), rgba(0, 196, 159, 0.08)),
		#f8fafc;
}

.howto-card__media img {
	width: 100%;
	height: 100%;
	max-height: 84px;
	object-fit: contain;
	filter: drop-shadow(0 10px 18px rgba(15, 23, 42, 0.16));
}

.howto-card__body {
	display: flex;
	flex-direction: column;
	padding: 16px;
}

.howto-card__label {
	color: #0f62fe;
	font-size: 10px;
	font-weight: 900;
	letter-spacing: 0;
	text-transform: uppercase;
}

.howto-card h3 {
	margin: 4px 0 7px;
	color: #111827;
	font-size: 17px;
	font-weight: 850;
	line-height: 1.25;
}

.howto-card p {
	flex: 1 1 auto;
	margin: 0 0 14px;
	color: #64748b;
	font-size: 12px;
	line-height: 1.45;
}

.howto-card__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.howto-modal-section {
	padding: 14px 16px;
	border: 1px solid rgba(15, 23, 42, 0.08);
	border-radius: 8px;
	background: #f8fafc;
}

.howto-modal-section + .howto-modal-section {
	margin-top: 12px;
}

.howto-modal-section h6 {
	display: flex;
	align-items: center;
	gap: 9px;
	margin: 0 0 7px;
	color: #111827;
	font-size: 14px;
	font-weight: 850;
}

.howto-modal-section h6 i {
	color: #0f62fe;
}

.howto-modal-section p {
	margin: 0;
	color: #475569;
	line-height: 1.6;
}

@media (max-width: 767px) {
	.public-page-hero {
		align-items: flex-start;
		flex-direction: column;
		padding: 18px;
	}

	.public-page-hero__stat {
		align-items: flex-start;
		width: 100%;
		min-height: auto;
		text-align: left;
	}

	.refer-code,
	.point-system-card__footer {
		align-items: stretch;
		flex-direction: column;
	}

	.referral-user-card {
		grid-template-columns: 56px minmax(0, 1fr);
	}

	.referral-user-card img {
		width: 56px;
		height: 56px;
	}

	.howto-hero {
		align-items: flex-start;
		flex-direction: column;
		padding: 18px;
	}

	.howto-grid {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 420px) {
	.howto-card {
		grid-template-columns: 1fr;
	}

	.howto-card__media {
		min-height: 118px;
	}
}
