@font-face {
	font-family: "Mikado";
	src: url("./fonts/MikadoRegular.woff2") format("woff2");
	font-style: normal;
	font-weight: 400;
	font-display: swap;
}

@font-face {
	font-family: "Mikado";
	src: url("./fonts/MikadoMedium.woff2") format("woff2");
	font-style: normal;
	font-weight: 500;
	font-display: swap;
}

@font-face {
	font-family: "Graphik";
	src: url("./fonts/Graphik-Regular-Web.woff2") format("woff2");
	font-style: normal;
	font-weight: 400;
	font-display: swap;
}

@font-face {
	font-family: "Graphik";
	src: url("./fonts/Graphik-Semibold-Web.woff2") format("woff2");
	font-style: normal;
	font-weight: 600;
	font-display: swap;
}

@font-face {
	font-family: "Graphik";
	src: url("./fonts/Graphik-Bold-Web.woff2") format("woff2");
	font-style: normal;
	font-weight: 700;
	font-display: swap;
}

:root {
	--osmo-red: #ea3729;
	--osmo-orange: #ff8a33;
	--osmo-cream: #fff8f1;
	--osmo-ink: #1a1a1a;
	--osmo-muted: #666b73;
	--osmo-line: #d9dde3;
	--osmo-panel: #f5f6f7;
	--osmo-card: #ffffff;
	--osmo-shadow: 0 20px 40px rgba(27, 31, 35, 0.08);
}

* {
	box-sizing: border-box;
}

[hidden] {
	display: none !important;
}

html,
body {
	margin: 0;
	padding: 0;
	background: #fff;
	color: var(--osmo-ink);
	font-family: "Graphik", sans-serif;
}

body {
	min-height: 100vh;
}

a,
button,
input {
	font: inherit;
}

button {
	cursor: pointer;
}

.container {
	width: min(1120px, calc(100vw - 32px));
	margin: 0 auto;
}

.hero {
	background: #ea3729;
	color: #fff;
	overflow: hidden;
}

.hero__inner {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(280px, 420px);
	gap: 32px;
	align-items: center;
	padding: 48px 0;
	position: relative;
}

.hero h1 {
	margin: 0;
	font-family: "Mikado", sans-serif;
	font-size: clamp(48px, 7vw, 72px);
	font-weight: 500;
	line-height: 1.05;
}

.hero p {
	max-width: 580px;
	margin: 20px 0 0;
	font-size: clamp(20px, 2.2vw, 24px);
	line-height: 1.45;
}

.hero__illustration {
	display: block;
	width: 100%;
	height: auto;
	object-fit: contain;
	align-self: end;
	justify-self: end;
	transform: translate(40px, 48px);
}

.page {
	padding: 56px 0 80px;
}

.toolbar {
	display: flex;
	gap: 24px;
	align-items: end;
	justify-content: space-between;
}

.toolbar h2 {
	margin: 0;
	font-family: "Mikado", sans-serif;
	font-size: clamp(36px, 4vw, 44px);
	font-weight: 500;
	line-height: 1.1;
}

.toolbar p {
	margin: 10px 0 0;
	font-size: 20px;
	line-height: 1.5;
	color: var(--osmo-muted);
}

.search {
	position: relative;
	display: block;
	width: min(100%, 380px);
	flex: 0 0 auto;
}

.search input {
	width: 100%;
	height: 56px;
	padding: 14px 52px 14px 52px;
	border: 1px solid #c8ccd2;
	border-radius: 14px;
	background: #fff;
	color: var(--osmo-ink);
	outline: none;
	transition: border-color 160ms ease, box-shadow 160ms ease;
}

.search input:focus {
	border-color: var(--osmo-orange);
	box-shadow: 0 0 0 4px rgba(255, 138, 51, 0.18);
}

.search__icon,
.search__clear {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 24px;
	height: 24px;
	background-repeat: no-repeat;
	background-position: center;
	background-size: contain;
}

.search__icon {
	left: 16px;
	pointer-events: none;
}

.search__icon--idle {
	background-image: url("./images/search-icon-white.png");
}

.search__icon--active {
	background-image: url("./images/search-icon-orange.png");
	opacity: 0;
}

.search:focus-within .search__icon--idle {
	opacity: 0;
}

.search:focus-within .search__icon--active {
	opacity: 1;
}

.search__clear {
	right: 16px;
	border: 0;
	padding: 0;
	background-color: transparent;
	background-image: url("./images/close-icon.png");
}

.manual-list {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 16px;
	padding-top: 36px;
}

.manual-card {
	display: flex;
	align-items: center;
	gap: 14px;
	width: 100%;
	padding: 12px;
	border: 1px solid var(--osmo-line);
	border-radius: 20px;
	background: var(--osmo-card);
	box-shadow: 0 1px 0 rgba(15, 23, 42, 0.02);
	text-align: left;
	text-decoration: none;
	color: inherit;
	transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.manual-card:hover,
.manual-card:focus-visible {
	transform: translateY(-1px);
	border-color: #f1b26c;
	box-shadow: var(--osmo-shadow);
	outline: none;
}

.manual-card__title {
	font-size: 18px;
	font-weight: 600;
	line-height: 1.35;
}

.game-icon {
	flex: 0 0 52px;
	width: 52px;
	height: 52px;
	border-radius: 12px;
	background-repeat: no-repeat;
	background-size: calc(100% * 11 + 25% * 10) calc(100% * 3 + 25% * 2);
	background-position: calc(var(--col) * 10%) calc(var(--row) * 50%);
}

.manual-empty {
	display: grid;
	grid-template-columns: auto 1fr auto;
	gap: 24px;
	align-items: center;
	margin-top: 36px;
	padding: 28px 32px;
	border: 2px dashed var(--osmo-line);
	border-radius: 24px;
	background: var(--osmo-panel);
}

.manual-empty h3 {
	margin: 0 0 10px;
	font-family: "Mikado", sans-serif;
	font-size: 30px;
	font-weight: 500;
	color: var(--osmo-red);
}

.manual-empty p {
	margin: 0;
	font-size: 18px;
	line-height: 1.45;
}

.manual-empty__mobile {
	display: none;
}

.button {
	min-height: 48px;
	padding: 0 20px;
	border: 0;
	border-radius: 999px;
	background: linear-gradient(135deg, #ff8a33, #ff6d1a);
	color: #fff;
	font-weight: 700;
	box-shadow: 0 12px 24px rgba(255, 138, 51, 0.28);
}

.footer {
	border-top: 1px solid #eceff2;
	padding: 28px 0 48px;
	background: #fbfbfc;
	color: var(--osmo-muted);
}

.footer p {
	margin: 0;
	font-size: 14px;
	line-height: 1.6;
}

.footer p + p {
	margin-top: 6px;
}

@media (max-width: 960px) {
	.hero__inner,
	.toolbar,
	.manual-empty {
		grid-template-columns: 1fr;
	}

	.hero__inner {
		padding: 40px 0;
	}

	.toolbar {
		display: grid;
		align-items: start;
	}

	.search {
		width: 100%;
	}

	.manual-list {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 640px) {
	.container {
		width: min(100vw - 24px, 1120px);
	}

	.page {
		padding: 32px 0 56px;
	}

	.hero__inner {
		gap: 20px;
	}

	.hero__illustration {
		max-width: 360px;
		margin: 0 auto;
		transform: translate(18px, 20px);
	}

	.toolbar p {
		font-size: 16px;
	}

	.manual-list {
		grid-template-columns: 1fr;
		padding-top: 24px;
	}

	.manual-card__title {
		font-size: 17px;
	}

	.manual-empty {
		padding: 24px 20px;
		gap: 16px;
	}

	.manual-empty__desktop {
		display: none;
	}

	.manual-empty__mobile {
		display: inline-block;
	}

	.manual-empty h3 {
		font-size: 24px;
	}

	.manual-empty p {
		font-size: 16px;
	}
}
