/* Clever Mobile Games: tokens and components taken from the clevermobile theme (theme.css), plus the few rules of this site at the end. */
:root {
	--bg: #f6f7f2;
	--surface: #ffffff;
	--surface-2: #eef0e8;
	--ink: #131615;
	--ink-2: #3a403c;
	--muted: #5f6761;
	--line: #e0e4d9;
	--lime: #9cc31b;
	--lime-2: #b4d82c;
	--lime-ink: #4a6100;
	--lime-soft: #edf5cf;
	--leaf-ink: #16191a;
	--shadow: 0 1px 2px rgb(20 30 10 / 6%), 0 8px 24px -8px rgb(20 30 10 / 12%);
	--shadow-lg: 0 2px 4px rgb(20 30 10 / 6%), 0 24px 48px -16px rgb(20 30 10 / 22%);
	--blob-1: #d9ef7a;
	--blob-2: #9fe7e1;
	--blob-3: #cbbcff;
	--r: 20px;
	--r-sm: 12px;
	--wrap: 1180px;
	--ease: cubic-bezier(.22, 1, .36, 1);
	--font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	--display: "Space Grotesk", var(--font);
	color-scheme: light;
}

@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) {
		--bg: #0c0e0d;
		--surface: #141816;
		--surface-2: #1a1f1c;
		--ink: #edf0e8;
		--ink-2: #c9cfc6;
		--muted: #98a199;
		--line: #262c28;
		--lime: #b6e02e;
		--lime-2: #cdeb5a;
		--lime-ink: #c9ec5c;
		--lime-soft: #232c0d;
		--leaf-ink: #eef1e8;
		--shadow: 0 1px 2px rgb(0 0 0 / 40%), 0 8px 24px -8px rgb(0 0 0 / 60%);
		--shadow-lg: 0 2px 4px rgb(0 0 0 / 40%), 0 24px 48px -16px rgb(0 0 0 / 70%);
		--blob-1: #4d6b06;
		--blob-2: #0d5f5a;
		--blob-3: #3b2d82;
		color-scheme: dark;
	}
}

:root[data-theme="dark"] {
	--bg: #0c0e0d;
	--surface: #141816;
	--surface-2: #1a1f1c;
	--ink: #edf0e8;
	--ink-2: #c9cfc6;
	--muted: #98a199;
	--line: #262c28;
	--lime: #b6e02e;
	--lime-2: #cdeb5a;
	--lime-ink: #c9ec5c;
	--lime-soft: #232c0d;
	--leaf-ink: #eef1e8;
	--shadow: 0 1px 2px rgb(0 0 0 / 40%), 0 8px 24px -8px rgb(0 0 0 / 60%);
	--shadow-lg: 0 2px 4px rgb(0 0 0 / 40%), 0 24px 48px -16px rgb(0 0 0 / 70%);
	--blob-1: #4d6b06;
	--blob-2: #0d5f5a;
	--blob-3: #3b2d82;
	color-scheme: dark;
}

/* ---------- base ---------- */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
	margin: 0;
	background: var(--bg);
	color: var(--ink);
	font: 400 17px/1.65 var(--font);
	-webkit-font-smoothing: antialiased;
	transition: background-color .4s var(--ease), color .4s var(--ease);
	overflow-x: hidden;
}
img, svg { max-width: 100%; height: auto; }
a { color: inherit; text-decoration-color: color-mix(in srgb, var(--lime) 70%, transparent); text-underline-offset: 3px; }
a:hover { color: var(--lime-ink); }
h1, h2, h3 { font-family: var(--display); font-weight: 600; letter-spacing: -.02em; line-height: 1.12; margin: 0 0 .5em; }
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
h3 { font-size: 1.25rem; }
::selection { background: var(--lime); color: #131615; }
:focus-visible { outline: 2px solid var(--lime); outline-offset: 3px; border-radius: 6px; }

.wrap { width: min(var(--wrap), 100% - 40px); margin-inline: auto; }
.wrap--narrow { width: min(760px, 100% - 40px); }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--ink); color: var(--bg); padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }
.i { width: 1.15em; height: 1.15em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

.eyebrow {
	display: inline-flex; align-items: center; gap: .5em;
	margin: 0 0 1rem; font: 600 .78rem/1 var(--font); letter-spacing: .12em; text-transform: uppercase; color: var(--lime-ink);
}
.eyebrow::before { content: ""; width: 18px; height: 2px; border-radius: 2px; background: var(--lime); }
.eyebrow a { text-decoration: none; }

/* ---------- logo ---------- */

.owl { overflow: visible; }
.owl__body { fill: var(--leaf-ink); transition: fill .4s; }
.owl__eye, .owl__bar { fill: var(--lime); }
.owl__beak { fill: var(--lime-2); }
.owl__pupil { fill: var(--bg); transition: fill .4s; }
.owl__pupils { translate: var(--px, 0) var(--py, 0); transition: translate .25s var(--ease); }
.owl__lid { fill: var(--leaf-ink); transform-box: fill-box; transform-origin: 50% 0; transform: scaleY(0); animation: blink 6s infinite; }
.owl__lid + .owl__lid { animation-delay: .02s; }
.owl.is-blinking .owl__lid { animation: blink-now .32s ease-in-out; }
@keyframes blink { 0%, 93%, 100% { transform: scaleY(0); } 95.5% { transform: scaleY(1); } }
@keyframes blink-now { 50% { transform: scaleY(1); } }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand__mark { width: 36px; height: 36px; transition: transform .5s var(--ease); }
.brand:hover .brand__mark { transform: rotate(-8deg) translateY(-2px); }
.brand__mark .owl__lid { animation-duration: 9s; }
.brand__word { font: 500 1.25rem/1 var(--display); letter-spacing: -.03em; }
.brand__word b { font-weight: 700; }

/* ---------- buttons ---------- */

.btn {
	--h: 50px;
	display: inline-flex; align-items: center; justify-content: center; gap: .55em;
	height: var(--h); padding: 0 22px; border-radius: 999px; border: 1px solid transparent;
	font: 600 .98rem/1 var(--font); text-decoration: none; white-space: nowrap; cursor: pointer;
	transition: transform .25s var(--ease), background-color .25s, box-shadow .25s, border-color .25s, color .25s;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(.98); }
.btn--sm { --h: 40px; padding: 0 16px; font-size: .9rem; }
.btn--primary { background: var(--ink); color: var(--bg); box-shadow: var(--shadow); }
.btn--primary:hover { color: var(--bg); box-shadow: 0 10px 30px -10px color-mix(in srgb, var(--lime) 80%, transparent); }
.btn--primary .i { transition: transform .25s var(--ease); }
.btn--primary:hover .i { transform: translateX(3px); }
.btn--ghost { border-color: var(--line); background: color-mix(in srgb, var(--surface) 70%, transparent); color: var(--ink); backdrop-filter: blur(8px); }
.btn--ghost:hover { border-color: var(--ink); color: var(--ink); }
.btn--play { background: #131615; color: #fff; border-color: #2c322e; }
.btn--play:hover { color: #fff; box-shadow: 0 10px 30px -12px rgb(0 0 0 / 50%); }
:root[data-theme="dark"] .btn--play { background: #edf0e8; color: #131615; border-color: #edf0e8; }
:root[data-theme="dark"] .btn--play:hover { color: #131615; }
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) .btn--play { background: #edf0e8; color: #131615; border-color: #edf0e8; }
	:root:not([data-theme="light"]) .btn--play:hover { color: #131615; }
}
.gp { width: 1.25em; height: 1.25em; }
.more { display: inline-flex; align-items: center; gap: .35em; font-weight: 600; text-decoration: none; color: var(--ink); }
.more .i { transition: transform .25s var(--ease); }
.more:hover { color: var(--lime-ink); }
.more:hover .i { transform: translateX(4px); }
.icon-btn {
	display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%;
	border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer;
	transition: transform .3s var(--ease), border-color .2s;
}
.icon-btn:hover { border-color: var(--ink); }
.icon-btn .i { grid-area: 1 / 1; transition: transform .5s var(--ease), opacity .3s; }
.badge {
	display: inline-flex; align-items: center; height: 28px; padding: 0 12px; border-radius: 999px;
	background: var(--lime-soft); color: var(--lime-ink); font: 600 .8rem/1 var(--font); white-space: nowrap;
}
.badge--muted { background: var(--surface-2); color: var(--muted); }
.badge--new { background: color-mix(in srgb, var(--a) 14%, var(--surface)); color: color-mix(in srgb, var(--a) 72%, var(--ink)); }

/* ---------- header ---------- */

.top {
	position: sticky; top: 0; z-index: 50;
	background: color-mix(in srgb, var(--bg) 72%, transparent);
	backdrop-filter: saturate(1.4) blur(16px); -webkit-backdrop-filter: saturate(1.4) blur(16px);
	border-bottom: 1px solid transparent; transition: border-color .3s, background-color .4s;
}
.top.is-scrolled { border-bottom-color: var(--line); }
.top__in { display: flex; align-items: center; gap: 16px; height: 72px; }
.nav { margin-left: auto; display: flex; align-items: center; gap: 20px; }
.nav ul { display: flex; gap: 4px; margin: 0; padding: 0; list-style: none; }
.nav a:not(.btn) {
	position: relative; display: block; padding: 8px 14px; border-radius: 999px;
	font-weight: 500; font-size: .96rem; text-decoration: none; color: var(--ink-2);
	transition: color .2s, background-color .2s;
}
.nav a:not(.btn):hover { color: var(--ink); background: var(--surface-2); }
.nav a[aria-current="page"] { color: var(--ink); }
.nav a[aria-current="page"]::after {
	content: ""; position: absolute; left: 50%; bottom: 2px; width: 5px; height: 5px; margin-left: -2.5px;
	border-radius: 50%; background: var(--lime);
}
.theme-toggle .i:last-child { opacity: 0; transform: rotate(-90deg) scale(.5); }
:root[data-theme="dark"] .theme-toggle .i:first-child { opacity: 0; transform: rotate(90deg) scale(.5); }
:root[data-theme="dark"] .theme-toggle .i:last-child { opacity: 1; transform: none; }
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) .theme-toggle .i:first-child { opacity: 0; transform: rotate(90deg) scale(.5); }
	:root:not([data-theme="light"]) .theme-toggle .i:last-child { opacity: 1; transform: none; }
}
.menu-toggle { display: none; }
.menu-toggle .i:last-child { opacity: 0; transform: rotate(-90deg); }
.menu-open .menu-toggle .i:first-child { opacity: 0; transform: rotate(90deg); }
.menu-open .menu-toggle .i:last-child { opacity: 1; transform: none; }

@media (max-width: 860px) {
	.menu-toggle { display: grid; }
	.theme-toggle { margin-left: auto; }
	.nav {
		position: fixed; inset: 72px 0 auto 0; z-index: 49; flex-direction: column; align-items: stretch; gap: 16px;
		margin: 0; padding: 20px; background: var(--bg); border-bottom: 1px solid var(--line);
		transform: translateY(-12px); opacity: 0; visibility: hidden;
		transition: transform .35s var(--ease), opacity .25s, visibility 0s .35s;
	}
	.menu-open .nav { transform: none; opacity: 1; visibility: visible; transition: transform .35s var(--ease), opacity .25s; }
	.nav ul { flex-direction: column; }
	.nav a:not(.btn) { font-size: 1.15rem; padding: 12px 14px; }
	.nav a[aria-current="page"]::after { left: auto; right: 16px; top: 50%; margin-top: -2.5px; }
}

.hero__bg { position: absolute; inset: -20% -10% auto; height: 140%; pointer-events: none; z-index: -1; filter: blur(70px); opacity: .7; }
.hero__bg span { position: absolute; border-radius: 50%; animation: drift 22s var(--ease) infinite alternate; }
.hero__bg span:nth-child(1) { width: 46vw; height: 46vw; left: 48%; top: 6%; background: var(--blob-1); }
.hero__bg span:nth-child(2) { width: 34vw; height: 34vw; left: 66%; top: 34%; background: var(--blob-2); animation-delay: -7s; animation-duration: 26s; }
.hero__bg span:nth-child(3) { width: 28vw; height: 28vw; left: 8%; top: 46%; background: var(--blob-3); opacity: .55; animation-delay: -13s; animation-duration: 30s; }
@keyframes drift {
	0% { transform: translate(0, 0) scale(1); }
	50% { transform: translate(-6vw, 4vw) scale(1.12); }
	100% { transform: translate(4vw, -3vw) scale(.94); }
}
@keyframes bob { 0%, 100% { translate: 0 0; } 50% { translate: 0 -10px; } }
.section { padding: clamp(56px, 8vw, 104px) 0; }
.section--flush { padding-top: 8px; }
.page-head { padding: clamp(40px, 6vw, 80px) 0 clamp(24px, 4vw, 40px); }
.page-head h1 { margin: 0; max-width: 18em; }
.page-head__lead { color: var(--muted); font-size: 1.15rem; max-width: 40em; margin: 1rem 0 0; }
.prose { max-width: 760px; padding-bottom: clamp(56px, 8vw, 96px); }
.prose > * { margin-block: 0 1.1em; }
.prose h2 { margin-top: 1.8em; font-size: 1.7rem; }
.prose h3 { margin-top: 1.6em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin: .35em 0; }
.prose li::marker { color: var(--lime-ink); }
/* ---------- games ---------- */

[hidden] { display: none !important; }

.games-head { position: relative; overflow: hidden; }
.games { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; }
.game-card {
	position: relative; display: flex; flex-direction: column; overflow: hidden; border-radius: var(--r);
	background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); text-decoration: none; color: var(--ink);
	transform: perspective(900px) rotateX(var(--rx, 0)) rotateY(var(--ry, 0)) translateY(var(--ty, 0));
	transition: transform .5s var(--ease), box-shadow .4s, border-color .4s;
}
.game-card:hover { --ty: -6px; color: var(--ink); box-shadow: 0 30px 60px -24px color-mix(in srgb, var(--a) 60%, transparent); border-color: color-mix(in srgb, var(--a) 50%, var(--line)); }
.game-card__art {
	display: grid; place-items: center; aspect-ratio: 16 / 9;
	background: radial-gradient(60% 80% at 30% 30%, color-mix(in srgb, var(--a) 45%, transparent), transparent 70%),
		radial-gradient(60% 80% at 75% 75%, color-mix(in srgb, var(--b) 45%, transparent), transparent 70%), #07041a;
}
.game-card__icon { border-radius: 26px; box-shadow: 0 0 40px color-mix(in srgb, var(--b) 60%, transparent); transition: transform .6s var(--ease); }
.game-card:hover .game-card__icon { transform: scale(1.08) rotate(-4deg); }
.game-card__body { display: flex; flex-direction: column; gap: 6px; padding: 20px 22px 8px; }
.game-card__title { font: 600 1.4rem/1.1 var(--display); }
.game-card__tag { color: var(--muted); font-size: .96rem; }
.game-card__by { color: var(--lime-ink); font-weight: 600; font-size: .88rem; }
.game-card__play { margin: 14px 22px 22px; align-self: start; }
.games-intro { margin-top: 40px; }

.games-teaser {
	display: flex; align-items: center; gap: 20px; padding: 20px 24px; border-radius: var(--r);
	text-decoration: none; color: #f2f0ff;
	background: radial-gradient(50% 120% at 0% 50%, color-mix(in srgb, var(--a) 40%, transparent), transparent 70%),
		radial-gradient(50% 120% at 100% 50%, color-mix(in srgb, var(--b) 35%, transparent), transparent 70%), #07041a;
	box-shadow: var(--shadow-lg); transition: transform .4s var(--ease);
}
.games-teaser:hover { transform: translateY(-3px); color: #fff; }
.games-teaser .game-icon { border-radius: 20px; flex: none; }
.games-teaser > span:nth-child(2) { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.games-teaser .eyebrow { color: #cdeb5a; margin: 0; }
.games-teaser b { font: 600 1.2rem/1.2 var(--display); }
.games-teaser small { color: #b9b3d6; }
.games-teaser .btn--primary { background: #f2f0ff; color: #07041a; }
@media (max-width: 640px) { .games-teaser { flex-wrap: wrap; } }

.game-hero { position: relative; overflow: hidden; padding: clamp(32px, 5vw, 72px) 0 clamp(48px, 7vw, 96px); }
.game-hero__in { display: grid; grid-template-columns: 1fr minmax(300px, 420px); gap: clamp(28px, 5vw, 64px); align-items: start; }
.game-hero__tag { font-size: 1.15rem; color: var(--ink-2); max-width: 32em; }
.game-hero__by { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; background: var(--lime-soft); color: var(--lime-ink); font-size: .92rem; }
.game-hero__h { font-size: 1.2rem; margin: 32px 0 12px; }
.game-steps { list-style: none; padding: 0; margin: 0 0 16px; display: grid; gap: 10px; }
.game-steps li { display: flex; gap: 12px; align-items: start; padding: 12px 14px; border-radius: var(--r-sm); background: var(--surface); border: 1px solid var(--line); }
.game-steps li span { display: grid; place-items: center; flex: none; width: 26px; height: 26px; border-radius: 50%; background: linear-gradient(135deg, var(--a), var(--b)); color: #fff; font-weight: 700; font-size: .85rem; }
.game-hero__controls { color: var(--muted); font-size: .95rem; }
.game-hero__in--wide { grid-template-columns: 1fr; }
.game-hero__in--wide .player { order: -1; position: static; }
@media (max-width: 900px) { .game-hero__in { grid-template-columns: 1fr; } .player { order: -1; } }

.player { position: sticky; top: 96px; display: grid; gap: 12px; }
.player__screen {
	position: relative; overflow: hidden; border-radius: 28px; background: #07041a;
	border: 10px solid #121018; box-shadow: 0 40px 80px -30px color-mix(in srgb, var(--a) 70%, transparent), 0 0 0 1px var(--line);
}
.player--portrait .player__screen { aspect-ratio: 9 / 16; max-height: 78vh; margin-inline: auto; width: 100%; }
.player--wide .player__screen { aspect-ratio: 16 / 9; width: 100%; }
.player__screen iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; background: #07041a; }
.player__start {
	position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
	border: 0; cursor: pointer; color: #f2f0ff; font: inherit;
	background: radial-gradient(60% 50% at 50% 40%, color-mix(in srgb, var(--a) 35%, transparent), transparent 70%), #07041a;
}
.player__icon { border-radius: 28px; box-shadow: 0 0 50px color-mix(in srgb, var(--b) 60%, transparent); animation: bob 4s ease-in-out infinite; }
.player__play { display: inline-flex; align-items: center; gap: 8px; height: 52px; padding: 0 26px; border-radius: 999px; background: linear-gradient(135deg, var(--a), var(--b)); font: 700 1.1rem/1 var(--display); transition: transform .3s var(--ease); }
.player__start:hover .player__play { transform: scale(1.06); }
.player__start small { color: #9c96b8; }
.player__bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
@media (max-width: 900px) { .player { position: static; } .player--portrait .player__screen { max-height: 82vh; width: min(100%, 46vh); } }

/* ---------- footer ---------- */

.foot { border-top: 1px solid var(--line); padding: 64px 0 28px; background: var(--surface-2); }
.foot__grid { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 40px; }
.foot__brand p { color: var(--muted); max-width: 22em; margin: 16px 0 20px; font-size: .95rem; }
.foot__h { font: 600 .78rem/1 var(--font); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin: 6px 0 16px; }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.foot ul a { text-decoration: none; color: var(--ink-2); font-size: .95rem; }
.foot ul a:hover { color: var(--lime-ink); }
.foot__base { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: .85rem; }
@media (max-width: 860px) { .foot__grid { grid-template-columns: 1fr 1fr; } .foot__brand { grid-column: 1 / -1; } }

/* ---------- motion ---------- */

/* reveal uses `translate`, so components keep their own `transform` (card tilt, hovers) */
.js .reveal { opacity: 0; translate: 0 22px; transition: opacity .8s var(--ease), translate .8s var(--ease), transform .5s var(--ease), box-shadow .4s, border-color .4s; }
.js .reveal.is-in { opacity: 1; translate: none; }

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
	.js .reveal { opacity: 1; translate: none; }
}


/* ---------- games site only ---------- */

.brand__sub { padding: 5px 10px; border-radius: 999px; background: var(--lime-soft); color: var(--lime-ink); font: 600 .78rem/1 var(--font); }
.games-head__in { display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.games-head__owl { width: min(190px, 24vw); flex: none; animation: bob 5s ease-in-out infinite; }
.foot__grid { grid-template-columns: 1.6fr 1fr 1fr; }
.game-hero__copy { min-width: 0; }
@media (max-width: 860px) { .foot__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .games { grid-template-columns: 1fr; } .games-head__owl { display: none; } }
@media (max-width: 400px) { .brand__sub { display: none; } .top__in { gap: 10px; } }
.g-robo-kick { --a: #4ff0ff; --b: #ffb347; }
.g-neon-recall { --a: #ff3fb0; --b: #3fe0ff; }
