@font-face {
	font-family: "NTSOMIC";
	src: url("../font/01_NTSOMIC-REGULAR.TTF") format("truetype");
	font-weight: 400;
	font-style: normal;
}

@font-face {
	font-family: "NTSOMIC";
	src: url("../font/02_NTSOMIC-MEDIUM.TTF") format("truetype");
	font-weight: 500;
	font-style: normal;
}

@font-face {
	font-family: "NTSOMIC";
	src: url("../font/03_NTSOMIC-BOLD.TTF") format("truetype");
	font-weight: 700;
	font-style: normal;
}

* {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

:root {
	--page-bg: #ececec;
	--text-color: #111;
	--sidebar-bg: #ffffff;
	--subtitle-color: #222;
	--menu-active-bg: rgba(0, 0, 0, 0.12);
	--lang-btn-bg: rgba(0, 0, 0, 0.12);
	--theme-transition: 0.32s ease;
}

html.dark {
	--page-bg: #1a1a1a;
	--text-color: #f2f2f2;
	--sidebar-bg: #141414;
	--subtitle-color: #e0e0e0;
	--menu-active-bg: rgba(255, 255, 255, 0.14);
	--lang-btn-bg: rgba(255, 255, 255, 0.2);
}

body {
	min-height: 100vh;
	background: var(--page-bg);
	font-family: "NTSOMIC", "Inter", "Segoe UI", Roboto, Arial, sans-serif;
	color: var(--text-color);
	overflow-x: hidden;
}

.sidebar {
	position: fixed;
	top: 0;
	left: 0;
	width: 340px;
	height: 100vh;
	padding: 24px;
	background: var(--sidebar-bg);
	display: flex;
	flex-direction: column;
	justify-content: space-between;
}

.mobile-nav {
	display: none;
}

.mobile-menu-checkbox {
	display: none;
}

.brand {
	display: flex;
	align-items: center;
	gap: 14px;
	margin-bottom: 26px;
}

.brand__logo {
	width: 76px;
	height: 76px;
	border-radius: 50%;
	display: block;
	object-fit: cover;
}

.brand__info {
	min-width: 0;
	display: flex;
	flex-direction: column;
}

.brand__title {
	font-size: 40px;
	line-height: 0.88;
	font-weight: 700;
	letter-spacing: 0.2px;
}

.brand__subtitle {
	margin-top: 4px;
	font-size: 30px;
	line-height: 0.9;
	font-weight: 400;
	color: var(--subtitle-color);
}

html[lang="ru"] .brand__title {
	order: 2;
}

html[lang="ru"] .brand__subtitle {
	order: 1;
	margin-top: 0;
	margin-bottom: 4px;
	font-size: 24px;
	line-height: 1;
}

.menu {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.menu__item {
	display: block;
	padding: 14px 16px;
	border-radius: 12px;
	color: var(--text-color);
	text-decoration: none;
	font-size: 22px;
	font-weight: 600;
	-webkit-tap-highlight-color: transparent;
}

.menu__item:hover,
.menu__item--active {
	background: var(--menu-active-bg);
}

.sidebar__bottom {
	padding-top: 16px;
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.menu-controls {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 10px 2px;
}

.language-toggle {
	display: flex;
	align-items: center;
	margin-left: 0;
}

.language-toggle__btn {
	border: 0;
	background: var(--lang-btn-bg);
	width: 4em;
	height: 2.2em;
	padding: 0;
	border-radius: 30px;
	font-family: inherit;
	font-size: 17px;
	font-weight: 600;
	color: var(--text-color);
	cursor: pointer;
	text-align: center;
	outline: none;
	-webkit-tap-highlight-color: transparent;
}

.language-toggle__btn:hover {
	opacity: 0.9;
	transform: translateY(-1px);
}

.main-content {
	margin-left: 340px;
	min-height: 100vh;
}

.site-disclaimer {
	position: fixed;
	left: 340px;
	right: 0;
	bottom: 0;
	max-width: calc(100vw - 340px);
	padding: 10px 16px;
	font-size: 12px;
	line-height: 1.25;
	color: var(--text-color);
	white-space: normal;
	word-break: break-word;
	overflow-wrap: anywhere;
	background: transparent;
	z-index: 5;
}

body,
.sidebar,
.brand__title,
.brand__subtitle,
.menu__item,
.language-toggle__btn,
.mobile-topbar,
.mobile-menu {
	transition: color var(--theme-transition), background-color var(--theme-transition), border-color var(--theme-transition);
	transition-delay: 0s;
}

.switch {
	font-size: 17px;
	position: relative;
	display: inline-block;
	width: 4em;
	height: 2.2em;
	border-radius: 30px;
	box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
	flex-shrink: 0;
	-webkit-tap-highlight-color: transparent;
}

.switch input {
	opacity: 0;
	width: 0;
	height: 0;
}

.slider {
	position: absolute;
	cursor: pointer;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background-color: #2a2a2a;
	transition: 0.4s;
	border-radius: 30px;
	overflow: hidden;
}

.slider:before {
	position: absolute;
	content: "";
	height: 1.2em;
	width: 1.2em;
	border-radius: 20px;
	left: 0.5em;
	bottom: 0.5em;
	transition: 0.4s;
	transition-timing-function: cubic-bezier(0.81, -0.04, 0.38, 1.5);
	box-shadow: inset 8px -4px 0 0 #fff;
}

.switch input:checked + .slider {
	background-color: #00a6ff;
}

.switch input:checked + .slider:before {
	transform: translateX(1.8em);
	box-shadow: inset 15px -4px 0 15px #ffcf48;
}

.star {
	background-color: #fff;
	border-radius: 50%;
	position: absolute;
	width: 5px;
	height: 5px;
	transition: all 0.4s;
}

.star_1 {
	left: 2.5em;
	top: 0.5em;
}

.star_2 {
	left: 2.2em;
	top: 1.2em;
}

.star_3 {
	left: 3em;
	top: 0.9em;
}

.switch input:checked + .slider .star {
	opacity: 0;
}

.cloud {
	width: 3.5em;
	position: absolute;
	bottom: -1.4em;
	left: -1.1em;
	opacity: 0;
	transition: all 0.4s;
}

.switch input:checked + .slider .cloud {
	opacity: 1;
}

@media (max-width: 900px) {
	.mobile-nav {
		display: block;
		position: relative;
		z-index: 15;
	}

	.mobile-topbar {
		height: 92px;
		background: #ffffff;
		display: flex;
		align-items: center;
		justify-content: space-between;
		gap: 12px;
		padding: 10px 14px;
	}

	html.dark .mobile-topbar {
		background: #141414;
	}

	.mobile-brand {
		display: flex;
		align-items: center;
		gap: 12px;
		min-width: 0;
	}

	.mobile-menu {
		display: block;
		position: absolute;
		top: 92px;
		left: 0;
		right: 0;
		padding: 14px;
		background: var(--sidebar-bg);
		border-bottom-left-radius: 14px;
		border-bottom-right-radius: 14px;
		max-height: 0;
		overflow: hidden;
		opacity: 0;
		transform: translateY(-8px);
		pointer-events: none;
		transition: max-height 0.28s ease, opacity 0.28s ease, transform 0.28s ease, background-color var(--theme-transition), color var(--theme-transition);
	}

	.mobile-menu .menu__item {
		margin-bottom: 8px;
		opacity: 0;
		transform: translateY(-6px);
		transition: opacity 0.2s ease, transform 0.2s ease, color var(--theme-transition), background-color var(--theme-transition);
		transition-delay: var(--menu-stagger, 0s), var(--menu-stagger, 0s), 0s, 0s;
	}

	.mobile-menu .menu__item:last-child {
		margin-bottom: 0;
	}

	.mobile-control-row {
		margin-top: 8px;
		opacity: 0;
		transform: translateY(-6px);
		transition: opacity 0.2s ease, transform 0.2s ease, color var(--theme-transition), background-color var(--theme-transition), border-color var(--theme-transition);
		transition-delay: var(--menu-stagger, 0s), var(--menu-stagger, 0s), 0s, 0s, 0s;
	}

	.mobile-menu-checkbox:checked ~ .mobile-menu {
		max-height: 520px;
		opacity: 1;
		transform: translateY(0);
		pointer-events: auto;
		transition: max-height 0.28s ease, opacity 0.28s ease, transform 0.28s ease, background-color var(--theme-transition), color var(--theme-transition);
	}

	.mobile-menu-checkbox:checked ~ .mobile-menu .menu__item,
	.mobile-menu-checkbox:checked ~ .mobile-menu .mobile-control-row {
		opacity: 1;
		transform: translateY(0);
	}

	.mobile-menu-checkbox:checked ~ .mobile-menu .menu__item:nth-child(1) { --menu-stagger: 0.10s; }
	.mobile-menu-checkbox:checked ~ .mobile-menu .menu__item:nth-child(2) { --menu-stagger: 0.14s; }
	.mobile-menu-checkbox:checked ~ .mobile-menu .menu__item:nth-child(3) { --menu-stagger: 0.18s; }
	.mobile-menu-checkbox:checked ~ .mobile-menu .menu__item:nth-child(4) { --menu-stagger: 0.22s; }
	.mobile-menu-checkbox:checked ~ .mobile-menu .mobile-control-row { --menu-stagger: 0.27s; }

	#mobile-menu-toggle {
		display: none;
	}

	.toggle {
		position: relative;
		width: 40px;
		cursor: pointer;
		display: block;
		height: calc(4px * 3 + 11px * 2);
		flex-shrink: 0;
		-webkit-tap-highlight-color: transparent;
	}

	.bar {
		position: absolute;
		left: 0;
		right: 0;
		height: 4px;
		border-radius: calc(4px / 2);
		background: #7b52b9;
		opacity: 1;
		transition: none 0.35s cubic-bezier(.5, -0.35, .35, 1.5) 0s;
	}

	.bar--top {
		bottom: calc(50% + 11px + 4px / 2);
		transition-property: bottom, transform;
		transition-delay: calc(0s + 0.35s), 0s;
	}

	.bar--middle {
		top: calc(50% - 4px / 2);
		transition-property: opacity;
		transition-delay: calc(0s + 0.35s);
	}

	.bar--bottom {
		top: calc(50% + 11px + 4px / 2);
		transition-property: top, transform;
		transition-delay: calc(0s + 0.35s), 0s;
	}

	.mobile-menu-checkbox:checked + .mobile-topbar .toggle .bar--top {
		bottom: calc(50% - 4px / 2);
		transform: rotate(135deg);
		transition-delay: 0s, calc(0s + 0.35s);
	}

	.mobile-menu-checkbox:checked + .mobile-topbar .toggle .bar--middle {
		opacity: 0;
		transition-duration: 0s;
		transition-delay: calc(0s + 0.35s);
	}

	.mobile-menu-checkbox:checked + .mobile-topbar .toggle .bar--bottom {
		top: calc(50% - 4px / 2);
		transform: rotate(225deg);
		transition-delay: 0s, calc(0s + 0.35s);
	}

	.sidebar {
		display: none;
	}

	.main-content {
		margin-left: 0;
		min-height: calc(100vh - 92px);
		overflow-x: hidden;
	}

	.site-disclaimer {
		position: static;
		left: auto;
		right: auto;
		bottom: auto;
		max-width: 100%;
		padding: 10px 14px 18px;
		white-space: normal;
	}

	.brand__logo {
		width: 64px;
		height: 64px;
	}

	.brand__title {
		font-size: 34px;
	}

	.brand__subtitle {
		font-size: 26px;
	}

	.menu__item {
		font-size: 20px;
	}

	.switch {
		font-size: 15px;
	}
}