div.foreground-window {
	display: block;
	position: absolute;
	padding: 0px;
	background-color: #222222;
	box-shadow: 0px 1px 5px #060606;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
	z-index: 7;
	cursor: default;
}

div.foreground-window.regular,
div.foreground-window.share {
	position: fixed;
	top: 50%;
	left: 50%;
	transform: translate(-50%, calc(-50% - 200px));
	width: 400px;
}

div.foreground-window#preview-window {
	position: fixed;
	top: 114px;
	left: 50%;
	transform: translateX(-50%);
	width: 1020px;
	height: 720px;
	/*padding: 35px 10px 10px 10px;*/
}

div.foreground-window#preview-window div.visualization {
	display: block;
	position: relative;
	width: 100%;
	height: calc(100% - 80px);
	background-image: url(/images/preview-surroundings-1.jpg);
	background-repeat: no-repeat;
	background-position: center center;
	background-size: cover;

/*	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
	box-shadow: inset 0 1px 5px #000000;*/

	overflow: hidden;
}

div.foreground-window#preview-window div.position {
	display: flex;
	justify-content: center;
	align-items: center;
	position: absolute;
}

div.foreground-window#preview-window div.controls {
	display: block;
	height: 80px;
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 10px;
	/*padding: 10px 0 0 0;*/
}

div.foreground-window#preview-window div.controls button {
	box-sizing: border-box;
	width: 50px;
	height: 50px;
	padding: 0;
	border: 2px solid #333333;
	border-radius: 50%;
	background-repeat: no-repeat;
	background-position: -4px -4px;
	background-size: 54px;
	background-clip: padding-box; /* фон начинается после border */
	box-shadow: inset 0px 0px 10px #090909, 0px 0px 3px #000000, 0px 0px 5px #000000;
	overflow: hidden;
	cursor: pointer;
	transition: filter 80ms;
}
div.foreground-window#preview-window div.controls button:hover {
	filter: brightness(1.2);
}

div.foreground-window#preview-window div.controls button:active {
	/*transform: scale(0.96);*/
}

button.refresh-preview.breach {
	background-image: url('/images/mechanics/breach.webp');
}
button.refresh-preview.delirium {
	background-image: url('/images/mechanics/delirium.webp');
}
button.refresh-preview.expedition {
	background-image: url('/images/mechanics/expedition.webp');
}
button.refresh-preview.abyss {
	background-image: url('/images/mechanics/abyss.webp');
}
button.refresh-preview.temple {
	background-image: url('/images/mechanics/temple.webp');
}

div.foreground-window div.header {
	padding: 10px 10px 0px 10px;
	font-size: 13px;
	color: #cccccc;
}

div.foreground-window div.close {
	position: absolute;
	top: 2px;
	right: 2px;
	width: 30px;
	height: 30px;
	background-image: url('../images/remove.png?v=2');
	background-size: 14px;
	background-repeat: no-repeat;
	background-position: center center;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
	cursor: pointer;
}
div.foreground-window div.close.out {
	top: 0px;
	right: -30px;
}
div.foreground-window div.close:hover {
	background-image: url('../images/remove-hover.png?v=2');
}
div.foreground-window div.close.out:hover {
}

div.foreground-window input[type=text],
div.foreground-window input[type=search] {
	width: 100%;
	height: 30px;
	padding: 0 10px;
	line-height: 30px;
	font-size: 13px;
	color: #cccccc;
	background-color: #141414;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
	border: none;
	outline: none;
}
div.foreground-window input[type=text]:hover,
div.foreground-window input[type=search]:hover {
	background-color: #131313;
}
div.foreground-window input[type=text]:focus,
div.foreground-window input[type=search]:focus {
	background-color: #121212;
}

div.foreground-window div.textarea {
	padding: 10px;
}

div.foreground-window div.copy-input {
	position: relative;
	padding: 10px 10px 10px 10px;
}

div.foreground-window div.copy-input input {
	height: 50px;
}

div.foreground-window div.copy-input button {
	position: absolute;
	top: 20px;
	right: 10px;
	width: 80px;
	height: 30px;
	padding: 1px 10px 0px 32px;
	background-image: url(/images/copy.png);
	background-size: 12px;
	background-repeat: no-repeat;
	background-position: 10px center;
}

div.foreground-window div.copy-input button.success {
	background-image: url(/images/success-white.png);
}



















/*div.foreground-window div.textarea input {
	width: 100%;
	height: 30px;
	padding: 8px 10px 8px 10px;
	margin: 0;
	font-size: 13px;
	color: #cccccc;
	background-color: #141414;
	border: none;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
}*/
/*div.foreground-window div.textarea input:hover {
	background-color: #171717;
}
div.foreground-window div.textarea input:focus {
	background-color: #161616;
}*/

div.foreground-window div.message {
	padding: 40px 10px 20px 10px;
	font-size: 13px;
	color: #cccccc;
	text-align: center;
	word-break: break-word;
}

div.foreground-window div.button {
	display: flex;
	justify-content: center;
	gap: 0;
	padding: 10px 5px 10px 5px;
}

div.foreground-window div.button.alert {
	padding: 20px 5px 20px 5px;
}

div.foreground-window button {
	width: 120px;
	height: 30px;
	margin: 0 10px;
	padding: 1px 0 0 0;
	line-height: 29px;
	font-size: 13px;
	text-decoration: none;
	background-size: 14px;
	background-repeat: no-repeat;
	background-position: 8px 8px;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
	border: none;
	outline: none;
	cursor: pointer;
}

div.foreground-window button.cancel {
	color: #cccccc;
	background-color: #333333;
	box-shadow: 0px 1px 3px #101010;
}
div.foreground-window button.cancel:hover {
	background-color: #383838;
}
div.foreground-window button.cancel:active {
	background-color: #3d3d3d;
}

div.foreground-window button.confirm {
	color: #ffffff;
	background-color: #00704c;
	box-shadow: 0px 1px 3px #101010;
}
div.foreground-window button.confirm:hover {
	background-color: #007a54;
}
div.foreground-window button.confirm:active {
	background-color: #00855b;
}
div.foreground-window button.confirm:disabled {
	color: #555555;
	background-color: #1a1a1a;
	cursor: default;
}

div.foreground-window button.confirm.loading {
	font-size: 0;
	background-size: 18px;
	background-repeat: no-repeat;
	background-position: center center;
	background-image: url('../images/loading-button-standout.gif');
}

div.foreground-window button.confirm.blank {
	padding: 1px 22px 0 0;
	background-size: 12px;
	background-repeat: no-repeat;
	background-position: right 9px center;
	background-image: url('../images/blank.png');
}

div.foreground-window div.parameters {
	display: flex;
	justify-content: start;
	padding: 5px 5px 0 5px;
/*	overflow: hidden;*/
}

div.foreground-window div.parameters.colunm {
	display: block;
}

div.foreground-window div.parameters div.search {
	margin: 5px 5px 10px 5px;
}

div.foreground-window div.parameters div.search input[type=search] {
	padding: 0 30px 0 32px;
	background-size: 14px;
	background-repeat: no-repeat;
	background-position: 8px 8px;
	background-image: url('../images/search.png');
}
div.foreground-window div.parameters div.search input[type=search]:hover,
div.foreground-window div.parameters div.search input[type=search]:focus {
	background-image: url('../images/search-focus.png');
}

div.foreground-window div.parameters > div.items {
	padding: 0 5px;
}

div.foreground-window div.parameters div.wrap {
	height: 210px;
	margin: 0 0 10px 0;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
	overflow: hidden;
}

div.foreground-window div.parameters div.parameters-block {
	width: 180px;
	height: 100%;
	background-color: #141414;
	overflow-y: auto;
/*	scrollbar-width: thin;*/
/*	scrollbar-color: #444444 transparent;*/
	user-select: none;
}
div.foreground-window div.parameters div.parameters-block::-webkit-scrollbar {
	width: 4px;
	background: transparent;
}
div.foreground-window div.parameters div.parameters-block::-webkit-scrollbar-thumb {
	background: #444444;
	border-radius: 2px;
}
div.foreground-window div.parameters div.parameters-block::-webkit-scrollbar-button {
	display: none;
}

div.foreground-window div.parameters div.parameters-block.items-block {
	width: 100%;
}

div.foreground-window div.parameters div.parameters-block.items-block.classes {
	padding: 5px 0 5px 0;
}

div.foreground-window div.parameters div.parameters-block label {
	display: block;
	position: relative;
	height: 30px;
	/*user-select: none;*/
}

div.foreground-window div.parameters div.parameters-block label.disabled {
	filter: brightness(0.5);
}

div.foreground-window div.parameters div.parameters-block label input {
	display: none;
}

div.foreground-window div.parameters div.parameters-block label:not(.disabled) div.image {
	cursor: pointer;
}

div.foreground-window div.parameters div.parameters-block label:not(.disabled) div.title:not(.group) {
	cursor: pointer;
}

div.foreground-window div.parameters div.parameters-block label div.title {
	display: block;
	padding: 1px 10px 0 10px;
	line-height: 29px;
	font-size: 13px;
	color: #cccccc;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

div.foreground-window div.parameters div.parameters-block label div.title.pad {
	padding: 1px 10px 0px 32px;
}

div.foreground-window div.parameters div.parameters-block div.title.group {
	height: 30px;
	line-height: 30px;
	font-size: 13px;
	padding: 1px 10px 0 10px;
	color: #bfbfa4;
}

div.foreground-window div.parameters div.parameters-block label div.color {
	display: block;
	position: absolute;
	top: 8px;
	left: 8px;
	width: 14px;
	height: 14px;
	border-radius: 50%;
	-moz-border-radius: 50%;
	-webkit-border-radius: 50%;
	box-shadow: inset 0px 0px 4px #ededed;
}

div.foreground-window div.parameters div.parameters-block label div.image {
	display: block;
	position: absolute;
	top: 0;
	left: 0;
	width: 30px;
	height: 30px;
}

div.foreground-window div.parameters div.parameters-block label div.image img {
	width: calc(100% - 6px);
	height: calc(100% - 6px);
	margin: 3px;
	object-fit: contain;
}

div.foreground-window div.parameters div.parameters-block label div.icon {
	position: absolute;
	top: 3px;
	left: 3px;
	display: block;
	width: 24px;
	height: 24px;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
}

div.foreground-window div.parameters div.parameters-block label div.icon img {
	width: 24px;
	height: 24px;
}

div.foreground-window div.parameters div.parameters-block label div.sound {
	display: none;
	position: absolute;
	top: 8px;
	right: 8px;
	width: 14px;
	height: 14px;
	background-image: url('../images/track.png');
	background-size: 14px;
	background-position: center center;
	background-repeat: no-repeat;
	cursor: pointer;
}
div.foreground-window div.parameters div.parameters-block label div.sound:hover {
	background-image: url('../images/track-hover.png');
}

div.foreground-window div.parameters div.parameters-block label:hover div.sound {
	display: block;
}

div.foreground-window div.parameters div.parameters-block.items label:not(.disabled):hover input:not(:checked) + div.title {
	background-color: #191919;
}

div.foreground-window div.parameters div.parameters-block label input:checked + div.title {
	background-color: #133328;
}

div.foreground-window div.parameters div.parameters-block label:hover input:checked + div.title {
	background-color: #163c2e;
}

div.foreground-window div.parameters div.parameters-block div.group {
	width: 100%;
	padding: 5px 5px 10px 5px;
}

div.foreground-window div.parameters div.parameters-block div.group label {
	display: inline-block;
	height: 20px;
	margin: 0 0 0 5px;
}

div.foreground-window div.parameters div.parameters-block div.group label div {
	line-height: 19px;
	padding: 1px 5px 0px 5px;
	background-color: #242424;
	border: 1px #2e2e2e solid;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
}
div.foreground-window div.parameters div.parameters-block div.group label:hover div {
	background-color: #2e2e2e;
	border: 1px #383838 solid;
}
div.foreground-window div.parameters div.parameters-block div.group label input:checked + div.title {
	border: 1px #173d30 solid;
}
div.foreground-window div.parameters div.parameters-block div.group label:hover input:checked + div.title {
	border: 1px #1a4737 solid;
}

div.foreground-window div.parameters div.parameters-buttons-block {
	display: inline-block;
	width: 180px;
	padding: 0;
	margin: 5px 5px 0 5px;
}

div.foreground-window div.parameters div.parameters-buttons-block.large {
	width: 200px;
}

div.foreground-window div.parameters div.font-block {
	width: 400px;
	padding: 5px;
	text-align: center;
}

div.foreground-window div.parameters div.pick-block {
	width: 350px;
	padding: 0 5px;
}

div.switch-button {
	position: relative;
	display: flex;
	width: 100%;
	height: 30px;
	margin: 0 0 10px 0;
	background-color: #333333;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
	cursor: pointer;
}
div.switch-button:hover {
	background-color: #383838;
}
div.switch-button:active {
	background-color: #3a3a3a;
}

div.switch-button > label {
	width: 100%;
	padding: 1px 0 0 40px;
	line-height: 29px;
	font-size: 13px;
	color: #cccccc;
	box-shadow: 0px 1px 3px #101010;
	user-select: none;
}
div.sets div.switch-button > label {
	padding: 1px 0 0 90px;
}

div.pad-block {
	margin: 0 0 10px 0;
}

div.pad-block div.title {
	position: relative;
	height: 40px;
/*	padding: 0 10px;*/
/*	width: calc(100% - 80px);*/
}

div.pad-block div.title span {
	position: absolute;
	top: 4px;
	left: 10px;
	line-height: 24px;
	font-size: 13px;
	color: #cccccc;
}

div.pad-block div.title div.play {
	display: none;
	position: absolute;
	top: 4px;
	right: 0;
	width: 22px;
	height: 22px;
	background-image: url('/images/track.png');
	background-size: 14px;
	background-position: 4px 4px;
	background-repeat: no-repeat;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
	cursor: pointer;
}
div.pad-block div.title div.play:hover {
	background-color: #383838;
	box-shadow: 0px 1px 3px #101010;
}
div.pad-block div.title div.play:active {
	background-color: #444444;
	box-shadow: 0px 1px 3px #101010;
}

/*range*/
div.range {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 30px;
}

div.range input[type=range] {
	appearance: none;
	-webkit-appearance: none;
	/*width: calc(100% - 20px);*/
	width: 100%;
	height: 10px;
	/*margin: 5px 10px 5px 10px;*/
	margin: 10px 0 10px 0;
	border-radius: 5px;
	-moz-border-radius: 5px;
	-webkit-border-radius: 5px;
	cursor: pointer;
	outline: none;
	border: none;
}

div.range input[type=range]::-moz-range-thumb {
	height: 16px;
	width: 16px;
	border-radius: 50%;
	-moz-border-radius: 50%;
	background-color: #999999;
	border: none;
}
div.range:hover input[type=range]::-moz-range-thumb {
	background-color: #c7c7c7;
}

div.range input[type=range]::-webkit-slider-thumb {
	appearance: none;
	-webkit-appearance: none;
	height: 16px;
	width: 16px;
	border-radius: 50%;
	-webkit-border-radius: 50%;
	background-color: #999999;
	border: none;
}
div.range:hover input[type=range]::-webkit-slider-thumb {
	background-color: #c7c7c7;
}
/*range*/

/*field*/
div.choice-buttons {
	display: flex;
	padding: 0 0 10px 0;
}

div.choice-buttons input {
	width: 0;
	height: 0;
	display: none;
}

div.choice-buttons label {
	position: relative;
	display: block;
	width: 90px;
	height: 30px;
	margin: 0;
	color: #cccccc;
	text-align: center;
	line-height: 29px;
	padding: 1px 10px 0px 10px;
	font-size: 13px;
	background-color: #141414;
	cursor: pointer;
	user-select: none;
	outline: none;
	border: none;
}
div.choice-buttons label:first-of-type {
	border-radius: 4px 0px 0px 4px;
	-moz-border-radius: 4px 0px 0px 4px;
	-webkit-border-radius: 4px 0px 0px 4px;
}
div.choice-buttons label:last-of-type {
	border-radius: 0px 4px 4px 0px;
	-moz-border-radius: 0px 4px 4px 0px;
	-webkit-border-radius: 0px 4px 4px 0px;
}
div.choice-buttons label:hover {
	background-color: #191919;
}
div.choice-buttons input[type="radio"]:checked + label {
	color: #eeeeee;
	background: #225947;
}

div.choice {
	display: none;
}
div.choice.active {
	display: block;
}

div.field-block {
	width: 100%;
	padding: 5px 5px 10px 5px;
}

div.sets {
	padding: 0 10px;
}

div.button-icons {
	position: absolute;
	top: 0;
	left: 35px;
	display: block;
}
div.button-icons > div {
	position: relative;
	width: 50px;
	height: 30px;
}

div.button-icons > div > img {
	position: absolute;
	top: 0;
	width: 22px;
	height: 22px;
	margin: 4px 0px;
	object-fit: contain;
	filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.5));
}
div.button-icons > div.c-1 > img:nth-child(1) {
	left: 14px;
}
div.button-icons > div.c-2 > img:nth-child(1) {
	left: 7px;
	z-index: 2;
}
div.button-icons > div.c-2 > img:nth-child(2) {
	left: 21px;
	z-index: 1;
}
div.button-icons > div.c-3 > img:nth-child(1) {
	left: 0px;
	z-index: 3;
}
div.button-icons > div.c-3 > img:nth-child(2) {
	left: 14px;
	z-index: 2;
}
div.button-icons > div.c-3 > img:nth-child(3) {
	left: 28px;
	z-index: 1;
}

div.buttons {
	display: flex;
}

div.buttons input[type=number] {
	height: 30px;
	font-size: 13px;
	text-align: center;
	color: #cccccc;
	background-color: #141414;
/*	-webkit-appearance: textfield;
	-moz-appearance: textfield;
	appearance: textfield;*/
	border: none;
	outline: none;
}

div.buttons input[type=number] {
	width: calc(100% - 100px);
}

div.buttons button {
	position: relative;
	display: block;
	width: 50px;
	height: 30px;
	margin: 0;
	align-items: center;
	color: #666666;
	font-size: 14px;
	background-color: #141414;
	cursor: pointer;
	outline: none;
	border: none;
}

div.buttons button.minus {
	border-radius: 4px 0px 0px 4px;
	-moz-border-radius: 4px 0px 0px 4px;
	-webkit-border-radius: 4px 0px 0px 4px;
}

div.buttons button.plus {
	border-radius: 0px 4px 4px 0px;
	-moz-border-radius: 0px 4px 4px 0px;
	-webkit-border-radius: 0px 4px 4px 0px;
}

div.buttons:hover input[type=number] {
	background-color: #131313
}
div.buttons input[type=number]:focus {
	background-color: #121212;
}

div.buttons:hover button,
div.buttons:active button {
	background-color: #131313;
	color: #cccccc;
}

div.buttons button:hover {
	background-color: #191919;
}
div.buttons button:active {
	background-color: #1c1c1c;
}

div.buttons input[type=number]::-webkit-inner-spin-button,
div.buttons input[type=number]::-webkit-outer-spin-button {
	-webkit-appearance: none;
}

div.double-input {
	display: flex;
}

div.double-input div {
	display: flex;
}

div.double-input div.symbol {
	width: 30px;
	line-height: 30px;
	color: #cccccc;
	justify-content: center;
}

div.double-input button {
	width: 20px;
}
div.double-input input[type=number] {
	width: 45px;
}

div.foreground-window div.social {
	display: flex;
	flex-wrap: wrap;
	justify-content: start;
	padding: 10px;
	overflow: hidden;
}
div.foreground-window div.social.center {
	justify-content: center;
}
div.foreground-window div.social div {
	float: left;
	display: block;
	position: relative;
	width: 20%;
}
div.foreground-window div.social div a {
	display: block;
	padding: 10px 5px 7px 5px;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
	text-decoration: none;
	overflow: hidden;
}
div.foreground-window div.social div a:hover {
	background-color: #333333;
}
div.foreground-window div.social div a:active {
	background-color: #444444;
}
div.foreground-window div.social div a div.logo {
	width: 100%;
	padding: 0px 5px;
}
div.foreground-window div.social div a div.logo img {
	width: 100%;
	aspect-ratio: 1/1;
	text-align: center;
	opacity: 0;
}
div.foreground-window div.social div a div.logo img.loaded {
	opacity: 1;
	transition: opacity 80ms;
}
div.foreground-window div.social div a div.title {
	width: 100%;
	padding: 10px 0px 0px 0px;
	text-align: center;
	font-size: 13px;
	color: #cccccc;
	text-overflow: fade;
	overflow: hidden;
}

div.overlay {
	position: fixed;
	background-color: #000000;
	opacity: 0.45;
	width: 100%;
	height: 100%;
	top: 0;
	left: 0;
	cursor: default;
}

div.overlay.fg-window {
	z-index: 6;
}

/*div.overlay.dd-window {
	z-index: 4;
	opacity: 0.25;
}*/

@media (min-width: 933px) {
	div.foreground-window button {
		/*margin: 0px 30px;*/
	}
}
@media (min-width: 0px) and (max-width: 932px) {
	div.foreground-window button {
		margin: 0px 20px;
	}
}

@media (min-width: 428px) {
	div.foreground-window {
/*		width: 520px;*/
	}
}
@media (min-width: 0px) and (max-width: 427px) {
	div.foreground-window {
		width: calc(100% - 20px);
	}
}













div.select {
	position: relative;
	user-select: none;
}

div.select div.selected {
	height: 30px;
	padding: 0 10px;
	line-height: 30px;
	font-size: 13px;
	color: #cccccc;
	background-color: #141414;
	border-radius: 4px;
	-moz-border-radius: 4px;
	-webkit-border-radius: 4px;
	cursor: pointer;
}
div.select.open div.selected {
	border-radius: 4px 4px 0px 0px;
	-moz-border-radius: 4px 4px 0px 0px;
	-webkit-border-radius: 4px 4px 0px 0px;
}

div.select div.options {
	position: absolute;
	width: 100%;
	background-color: #141414;
	border-radius: 0px 0px 4px 4px;
	-moz-border-radius: 0px 0px 4px 4px;
	-webkit-border-radius: 0px 0px 4px 4px;
	z-index: 3;
	overflow: hidden;
	display: none;

/*	max-height: 0;
	transform: scaleY(1);
	transform-origin: top;
	transition: max-height 0.2s ease, transform 0.2s ease;*/
}

div.select div.options div {
	height: 30px;
	padding: 0 10px;
	line-height: 30px;
	font-size: 13px;
	color: #cccccc;
	background-color: #141414;
	cursor: pointer;
}

div.select div.options div:hover {
	background-color: #1e1e1e;
}

div.select.open div.options {
	display: block;

/*	max-height: 300px;
	transform: scaleY(1);*/
}