.minicolors {
  position: relative;
}

.minicolors-sprite {
  background-image: url("/svg-editor/lib/minicolors-latest/jquery.minicolors.png");
}

.minicolors-swatch {
  position: absolute;
  vertical-align: middle;
  background-position: -80px 0;
  border: solid 1px #ccc;
  cursor: text;
  padding: 0;
  margin: 0;
  display: inline-block;
}

.minicolors-swatch-color {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}

.minicolors input[type=hidden] + .minicolors-swatch {
  width: 28px;
  position: static;
  cursor: pointer;
}

.minicolors input[type=hidden][disabled] + .minicolors-swatch {
  cursor: default;
}

/* Panel */
.minicolors-panel {
  position: absolute;
  width: 173px;
  background: white;
  border: solid 1px #CCC;
  box-shadow: 0 0 20px rgba(0, 0, 0, .2);
  z-index: 99999;
  box-sizing: content-box;
  display: none;
}

.minicolors-panel.minicolors-visible {
  display: block;
}

/* Panel positioning */
.minicolors-position-top .minicolors-panel {
  top: -154px;
}

.minicolors-position-right .minicolors-panel {
  right: 0;
}

.minicolors-position-bottom .minicolors-panel {
  top: auto;
}

.minicolors-position-left .minicolors-panel {
  left: 0;
}

.minicolors-with-opacity .minicolors-panel {
  width: 194px;
}

.minicolors .minicolors-grid {
  position: relative;
  top: 1px;
  left: 1px; /* LTR */
  width: 150px;
  height: 150px;
  margin-bottom: 2px;
  background-position: -120px 0;
  cursor: crosshair;
}
[dir=rtl] .minicolors .minicolors-grid {
  right: 1px;
}

.minicolors .minicolors-grid-inner {
  position: absolute;
  top: 0;
  left: 0;
  width: 150px;
  height: 150px;
}

.minicolors-slider-saturation .minicolors-grid {
  background-position: -420px 0;
}

.minicolors-slider-saturation .minicolors-grid-inner {
  background-position: -270px 0;
  background-image: inherit;
}

.minicolors-slider-brightness .minicolors-grid {
  background-position: -570px 0;
}

.minicolors-slider-brightness .minicolors-grid-inner {
  background-color: black;
}

.minicolors-slider-wheel .minicolors-grid {
  background-position: -720px 0;
}

.minicolors-slider,
.minicolors-opacity-slider {
  position: absolute;
  top: 1px;
  left: 152px; /* LTR */
  width: 20px;
  height: 150px;
  background-color: white;
  background-position: 0 0;
  cursor: row-resize;
}
[dir=rtl] .minicolors-slider,
[dir=rtl] .minicolors-opacity-slider {
  right: 152px;
}

.minicolors-slider-saturation .minicolors-slider {
  background-position: -60px 0;
}

.minicolors-slider-brightness .minicolors-slider {
  background-position: -20px 0;
}

.minicolors-slider-wheel .minicolors-slider {
  background-position: -20px 0;
}

.minicolors-opacity-slider {
  left: 173px; /* LTR */
  background-position: -40px 0;
  display: none;
}
[dir=rtl] .minicolors-opacity-slider {
  right: 173px;
}

.minicolors-with-opacity .minicolors-opacity-slider {
  display: block;
}

/* Pickers */
.minicolors-grid .minicolors-picker {
  position: absolute;
  top: 70px;
  left: 70px;
  width: 12px;
  height: 12px;
  border: solid 1px black;
  border-radius: 10px;
  margin-top: -6px;
  margin-left: -6px;
  background: none;
}

.minicolors-grid .minicolors-picker > div {
  position: absolute;
  top: 0;
  left: 0;
  width: 8px;
  height: 8px;
  border-radius: 8px;
  border: solid 2px white;
  box-sizing: content-box;
}

.minicolors-picker {
  position: absolute;
  top: 0;
  left: 0;
  width: 18px;
  height: 2px;
  background: white;
  border: solid 1px black;
  margin-top: -2px;
  box-sizing: content-box;
}

/* Swatches */
.minicolors-swatches,
.minicolors-swatches li {
  margin: 5px 0 3px 5px; /* LTR */
  padding: 0;
  list-style: none;
  overflow: hidden;
}
[dir=rtl] .minicolors-swatches,
[dir=rtl] .minicolors-swatches li {
  margin: 5px 5px 3px 0;
}

.minicolors-swatches .minicolors-swatch {
  position: relative;
  float: left; /* LTR */
  cursor: pointer;
  margin:0 4px 0 0; /* LTR */
}
[dir=rtl] .minicolors-swatches .minicolors-swatch {
  float: right;
  margin:0 0 0 4px;
}

.minicolors-with-opacity .minicolors-swatches .minicolors-swatch {
  margin-right: 7px; /* LTR */
}
[dir=rtl] .minicolors-with-opacity .minicolors-swatches .minicolors-swatch {
  margin-right: 0;
  margin-left: 7px;
}

.minicolors-swatch.selected {
  border-color: #000;
}

/* Inline controls */
.minicolors-inline {
  display: inline-block;
}

.minicolors-inline .minicolors-input {
  display: none !important;
}

.minicolors-inline .minicolors-panel {
  position: relative;
  top: auto;
  left: auto; /* LTR */
  box-shadow: none;
  z-index: auto;
  display: inline-block;
}
[dir=rtl] .minicolors-inline .minicolors-panel {
  right: auto;
}

/* Default theme */
.minicolors-theme-default .minicolors-swatch {
  top: 5px;
  left: 5px; /* LTR */
  width: 18px;
  height: 18px;
}
[dir=rtl] .minicolors-theme-default .minicolors-swatch {
  right: 5px;
}
.minicolors-theme-default .minicolors-swatches .minicolors-swatch {
  margin-bottom: 2px;
  top: 0;
  left: 0; /* LTR */
  width: 18px;
  height: 18px;
}
[dir=rtl] .minicolors-theme-default .minicolors-swatches .minicolors-swatch {
  right: 0;
}
.minicolors-theme-default.minicolors-position-right .minicolors-swatch {
  left: auto; /* LTR */
  right: 5px; /* LTR */
}
[dir=rtl] .minicolors-theme-default.minicolors-position-left .minicolors-swatch {
  right: auto;
  left: 5px;
}
.minicolors-theme-default.minicolors {
  width: auto;
  display: inline-block;
}
.minicolors-theme-default .minicolors-input {
  height: 20px;
  width: auto;
  display: inline-block;
  padding-left: 26px; /* LTR */
}
[dir=rtl] .minicolors-theme-default .minicolors-input {
  text-align: right;
  unicode-bidi: plaintext;
  padding-left: 1px;
  padding-right: 26px;
}
.minicolors-theme-default.minicolors-position-right .minicolors-input {
  padding-right: 26px; /* LTR */
  padding-left: inherit; /* LTR */
}
[dir=rtl] .minicolors-theme-default.minicolors-position-left .minicolors-input {
  padding-right: inherit;
  padding-left: 26px;
}

/* Bootstrap theme */
.minicolors-theme-bootstrap .minicolors-swatch {
  z-index: 2;
  top: 3px;
  left: 3px; /* LTR */
  width: 28px;
  height: 28px;
  border-radius: 3px;
}
[dir=rtl] .minicolors-theme-bootstrap .minicolors-swatch {
  right: 3px;
}
.minicolors-theme-bootstrap .minicolors-swatches .minicolors-swatch {
  margin-bottom: 2px;
  top: 0;
  left: 0; /* LTR */
  width: 20px;
  height: 20px;
}
[dir=rtl] .minicolors-theme-bootstrap .minicolors-swatches .minicolors-swatch {
  right: 0;
}
.minicolors-theme-bootstrap .minicolors-swatch-color {
  border-radius: inherit;
}
.minicolors-theme-bootstrap.minicolors-position-right > .minicolors-swatch {
  left: auto; /* LTR */
  right: 3px; /* LTR */
}
[dir=rtl] .minicolors-theme-bootstrap.minicolors-position-left > .minicolors-swatch {
  right: auto;
  left: 3px;
}
.minicolors-theme-bootstrap .minicolors-input {
  float: none;
  padding-left: 44px; /* LTR */
}
[dir=rtl] .minicolors-theme-bootstrap .minicolors-input {
  text-align: right;
  unicode-bidi: plaintext;
  padding-left: 12px;
  padding-right: 44px;
}
.minicolors-theme-bootstrap.minicolors-position-right .minicolors-input {
  padding-right: 44px; /* LTR */
  padding-left: 12px; /* LTR */
}
[dir=rtl] .minicolors-theme-bootstrap.minicolors-position-left .minicolors-input {
  padding-right: 12px;
  padding-left: 44px;
}
.minicolors-theme-bootstrap .minicolors-input.input-lg + .minicolors-swatch {
  top: 4px;
  left: 4px; /* LTR */
  width: 37px;
  height: 37px;
  border-radius: 5px;
}
[dir=rtl] .minicolors-theme-bootstrap .minicolors-input.input-lg + .minicolors-swatch {
  right: 4px;
}
.minicolors-theme-bootstrap .minicolors-input.input-sm + .minicolors-swatch {
  width: 24px;
  height: 24px;
}
.minicolors-theme-bootstrap .minicolors-input.input-xs + .minicolors-swatch {
  width: 18px;
  height: 18px;
}
.input-group .minicolors-theme-bootstrap:not(:first-child) .minicolors-input {
  border-top-left-radius: 0; /* LTR */
  border-bottom-left-radius: 0; /* LTR */
}
[dir=rtl] .input-group .minicolors-theme-bootstrap .minicolors-input {
  border-radius: 4px;
}
[dir=rtl] .input-group .minicolors-theme-bootstrap:not(:first-child) .minicolors-input {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}
[dir=rtl] .input-group .minicolors-theme-bootstrap:not(:last-child) .minicolors-input {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}
/* bootstrap input-group rtl override */
[dir=rtl] .input-group .form-control,
[dir=rtl] .input-group-addon,
[dir=rtl] .input-group-btn > .btn,
[dir=rtl] .input-group-btn > .btn-group > .btn,
[dir=rtl] .input-group-btn > .dropdown-toggle {
  border: 1px solid #ccc;
  border-radius: 4px;
}
[dir=rtl] .input-group .form-control:first-child,
[dir=rtl] .input-group-addon:first-child,
[dir=rtl] .input-group-btn:first-child > .btn,
[dir=rtl] .input-group-btn:first-child > .btn-group > .btn,
[dir=rtl] .input-group-btn:first-child > .dropdown-toggle,
[dir=rtl] .input-group-btn:last-child > .btn:not(:last-child):not(.dropdown-toggle),
[dir=rtl] .input-group-btn:last-child > .btn-group:not(:last-child) > .btn {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  border-left: 0;
}
[dir=rtl] .input-group .form-control:last-child,
[dir=rtl] .input-group-addon:last-child,
[dir=rtl] .input-group-btn:last-child > .btn,
[dir=rtl] .input-group-btn:last-child > .btn-group > .btn,
[dir=rtl] .input-group-btn:last-child > .dropdown-toggle,
[dir=rtl] .input-group-btn:first-child > .btn:not(:first-child),
[dir=rtl] .input-group-btn:first-child > .btn-group:not(:first-child) > .btn {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

/* Semantic Ui theme */
.minicolors-theme-semanticui .minicolors-swatch {
  top: 0;
  left: 0; /* LTR */
  padding: 18px;
}
[dir=rtl] .minicolors-theme-semanticui .minicolors-swatch {
  right: 0;
}
.minicolors-theme-semanticui input {
  text-indent: 30px;
}
/* ---------------------------------------------------------------------------------------------------- */

/*
	z-index:
		.editor												10
			.editor-help-bar								-
			.wrap
				.editor-menu-bar							20
				.editor-control-item[data-name="area"]		20
				.editor-messages							20
				.editor-artboard							10
				.editor-progress-bar						20
				.editor-controls							30
				.editor-tools								40
				.editor-popup								50

	@link-color: #4C98A2
*/

.editor {
	display: block !important; /* Show editor after async styles loading */
	min-width: 360px;
	/* border: 1px solid #e5e5e5; */
	position: relative;
	z-index: 10;
	font-size: 16px;
	line-height: 1.5;
	/* background: coral; */
}

.editor > .wrap {
	position: relative;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-help-bar {
	border-radius: 6px;
	margin: 0 20px 20px;
	padding: 10px 15px;
	background: rgba(0,0,0,0.03);
	color: rgba(0,0,0,0.5);
	font-size: 13px;
	text-align: center;
}

@media (min-width: 768px) {
	.editor-help-bar {
		margin-left: 0;
		margin-right: 0;
	}
}

.editor-help-bar > span:not(:last-child) {
	margin-right: 0.15em;
}

.editor-help-bar > span:nth-child(2) {
	display: inline-block;
}

.editor-help-bar .editor-control-item[data-name="decoration-method"] {
	color: rgba(0,0,0,0.7);
	font-weight: 700;
	white-space: nowrap;
	cursor: pointer;
	user-select: none;
}

.editor-help-bar .editor-control-item[data-name="decoration-method"]:not(:last-child) {
	margin-right: 0.15em;
}

.editor-help-bar .editor-control-item[data-name="decoration-method"]:not(:last-child)::after {
	content: ",";
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-menu-bar {
	min-height: 30px;
	margin: 0 20px;
	padding: 5px 0 6px;
	position: relative;
	z-index: 20;
	/* background: silver; */
}

@media (min-width: 768px) {
	.editor-menu-bar {
		margin-left: 0;
		margin-right: 0;
	}
}

.editor-menu-bar.hidden {
	display: block !important;
	visibility: hidden;
}

.editor-menu-bar::after {
	content: " ";
	display: table;
	width: 0;
	height: 0;
	clear: both;
}

.editor-menu-bar > div {}

.editor-menu-bar .editor-control-item[data-name="threads"] {
	float: right;
	/* color: rgba(0,0,0,0.75); */
	font-size: 13px;
	font-weight: bold;
	line-height: 19px;
}

.editor-menu-bar .pseudo-select {
	margin-right: 20px;
	float: left;
	/* clear: left; */
}

.editor-menu-bar .pseudo-select label {
	/* color: rgba(0,0,0,0.75); */
	font-size: 13px;
	font-weight: bold;
	line-height: 19px;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-control-item[data-name="threads"] {
	cursor: pointer;
}

.editor-control-item[data-name="threads"] > span {
	display: table-cell;
	vertical-align: middle;
}

.editor-control-item[data-name="threads"] > span:first-child {
	padding-right: 0.25em;
}

.editor-control-item[data-name="threads"] .thread-color {
	display: block;
	width: 12px;
	height: 12px;
	margin-left: 4px;
	overflow: hidden;
	float: left;
	position: relative;
}

.editor-control-item[data-name="threads"] .thread-color::after {
    content: "";
    display: block;
    border: 1px solid rgba(0,0,0,0.1);
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-control-item[data-name="area"] {
	padding: 4px 0;
	position: absolute;
	left: 20px;
	z-index: 20;
	font-size: 12px;
	line-height: 1;
	cursor: pointer;
	/* background: silver; */
}

.editor:not(.ready) .editor-control-item[data-name="area"] {
	display: none;
}

@media (min-width: 768px) {
	.editor-control-item[data-name="area"] {
		left: 0;
	}
}

.editor-control-item[data-name="area"]:not(.text-primary) {
	color: rgba(0,0,0,0.5);
}

.editor-control-item[data-name="area"] a {
	color: inherit;
	text-decoration: none;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-messages {
	margin-top: 25px;
	position: absolute;
	left: 20px;
	z-index: 20;
	background: rgba(255,255,255,0.9);
	font-size: 12px;
	line-height: 1;
	/* background: silver; */
}

.editor:not(.ready) .editor-messages {
	display: none;
}

@media (min-width: 768px) {
	.editor-messages {
		left: 0;
	}
}

.editor-messages ul {
	margin: -5px 0 0 -9px;
	overflow: hidden;
	list-style: none;
}

.editor-messages ul > li {
	display: block;
	margin: 0;
	padding: 0;
	float: left;
}

@media (min-width: 992px) {
	.editor-messages ul > li {
		float: none;
	}
}

.editor-message-item {
	margin: 5px 0 0 5px;
	padding: 4px;
	font-weight: bold;
}

.editor-message-item .glyphicon {
	line-height: 0;
}

.editor-message-item[data-name="quality"]:not(.text-warning):not(.text-danger) .glyphicon {
	display: none !important;
}

.editor-message-item[data-name="quality"] [data-name="quality-value"]:not(:empty)::before {
	content: "(";
}

.editor-message-item[data-name="quality"] [data-name="quality-value"]:not(:empty)::after {
	content: ")";
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-artboard {
	display: flex;
	align-items: center;
	min-height: 455px; /* 575 - 30 - 50 - 40 */
	margin: 25px 20px;
	overflow: hidden;
	position: relative;
	z-index: 10;
	/* background: coral; */
}

@media (min-width: 768px) {
	.editor-artboard {
		margin-left: 0;
		margin-right: 0;
	}
}

#svg-editor {
	flex: 1 1 auto;
	min-width: 320px;
	min-height: 375px;
	aspect-ratio: 1024 / 1200;
	margin: 0 auto;
	/* padding-bottom: 117.1875%; */
	position: relative;
}

@media (min-width: 768px) {
	#svg-editor {
		max-height: max(455px, calc(100vh - 30px - 50px - 40px - 30px));
	}
}

#svg-editor svg {
	display: block;
	width: auto;
	max-width: 100%;
	height: auto;
	max-height: 100%;
	margin: auto;
	position: absolute;
	inset: 0;
	user-select: none;
	-webkit-touch-callout: none;
}

#svg-editor svg[width][height] {
	display: none !important;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor progress {
	display: block;
	width: 100%;
	height: 2px;
	border: 0;
	box-shadow: none;
	appearance: none;
	color: transparent;
}

.editor progress:not([value]),
.editor progress[value="0"] {
	display: none;
}

.editor progress::-moz-progress-bar {
	background: #4C98A2;
}

.editor progress::-webkit-progress-bar {
	background: transparent;
}

.editor progress::-webkit-progress-value {
	background: #4C98A2;
}

.editor-progress-bar {
	position: absolute;
	left: 0;
	right: 0;
	z-index: 20;
	bottom: 60px;
	transform: translate(0, 100%);
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-controls {
	height: 40px;
	/* margin: 0 3%; */
	margin: 0 20px;
	position: relative;
	z-index: 30;
	/* background: silver; */
}

@media (min-width: 768px) {
	.editor-controls {
		margin-left: 0;
		margin-right: 0;
	}
}

.editor-controls ul {
	display: flex;
	flex-flow: row nowrap;
	gap: 5px;
	width: 100%;
	margin: 0;
	overflow: hidden;
	list-style: none;
}

.editor-controls ul > li {
	flex: 1 1 auto;
	margin: 0;
	padding: 0;
	/* background: coral; */
}

.editor-controls .editor-control-item {
	display: block;
	min-width: 40px;
	height: 40px;
	position: relative;
	background: url("/i/others/blank.png") center center / 40px 40px no-repeat;
	cursor: pointer;
	transition: background-size 0.1s;
}

.editor-controls .editor-control-item::before {
	content: "";
	display: block;
	border: 1px solid rgba(0,0,0,0.1);
	border-radius: 20px;
	position: absolute;
	inset: 0;
}

@media (hover: hover) {
	.editor-controls .editor-control-item:hover {
		background-size: 44px 44px;
	}

	/* .editor-controls .editor-control-item:hover::before {
		border-color: #4C98A2;
	} */
}

.editor-control-item[data-name="image"] {
	background-image: url("/svg-editor/images/controls/image.svg");
}

.editor-control-item[data-name="text"] {
	background-image: url("/svg-editor/images/controls/text.svg");
}

.editor-control-item[data-name="art"] {
	background-image: url("/svg-editor/images/controls/art.svg");
}

.editor-control-item[data-name="upload"] {
	background-image: url("/svg-editor/images/controls/upload.svg");
}

.editor-control-item[data-name="upload"] form {
	width: 100%;
	height: 100%;
	margin: 0;
	overflow: hidden;
	position: absolute;
	left: 0;
	right: 0;
	top: 0;
	bottom: 0;
	opacity: 0;
}

.editor-control-item[data-name="upload"] form input {
	display: block;
	width: 100%;
	height: 200%;
	border: 0;
	margin: 0;
	padding: 0;
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	cursor: pointer;
}

.editor-control-item[data-name="preview"] {
	background-image: url("/svg-editor/images/controls/preview.svg");
}

.editor-control-item[data-name="download"] {
	background-image: url("/svg-editor/images/controls/download.svg");
}

.editor-control-item[data-name="reset"] {
	background-image: url("/svg-editor/images/controls/reset.svg");
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tools {
	height: 150px;
	margin: 0;
	box-sizing: border-box;
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 40;
	/* color: rgba(0,0,0,0.75); */
	font-weight: bold;
	opacity: 0;
	visibility: hidden;
}

.editor-tools-toggle {
	width: 40px;
	height: 40px;
	float: right;
	background: url("/svg-editor/images/controls/close.svg") 0 0 / 100% 100% no-repeat;
	cursor: pointer;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-group[data-name="actions"] {
	height: 40px;
	padding: 0 20px;
	background: rgba(255,255,255,0.85);
	font-weight: bold;
	line-height: 40px;
}

.editor-tool-group[data-name="actions"] ul {
	display: none;
}

.editor-tool-group[data-name="actions"] > .editor-tool-item {
	float: left;
}

.editor-tool-group[data-name="actions"] > .editor-tool-item:not(:last-child) {
	margin-right: 15px;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-group[data-name="properties"] {
	height: 110px;
	overflow: hidden;
	background: #f7f7f7;
}

.editor-tool-group[data-name="properties"] .editor-tool-group {
	min-width: 280px;
	margin: 0 40px;
	padding: 20px 0;
}

.editor-tool-group[data-name="properties"] .editor-tool-group-heading {
	height: 30px;
	font-weight: bold;
	line-height: 1;
}

.editor-tool-group[data-name="properties"] .editor-tool-group-content {
	height: 40px;
	margin-top: 30px;
	position: relative;
}

.editor-tool-group[data-name="properties"] .editor-tool-group-heading + .editor-tool-group-content {
	margin-top: 0;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-item[data-type="button"] {
	display: block;
	width: 40px;
	height: 40px;
	overflow: hidden;
	float: left;
	position: relative;
	background: url("/i/others/blank.png") center center / 40px 40px no-repeat;
	cursor: pointer;
}

.editor-tool-item[data-type="button"].active {
	cursor: default;
}

.editor-tool-item[data-type="button"].disabled {
	opacity: 0.5;
	cursor: default;
}

.editor-tool-item[data-type="button"] + .editor-tool-item[data-type="button"] {
	margin-left: 7.5px;
}

.editor-tool-item[data-type="button"]::before {
	content: "";
	display: block;
	width: inherit;
	height: inherit;
	position: absolute;
	left: 0;
	right: 0;
	top: 0;
	bottom: 0;
	z-index: 1;
	background: url("/i/others/blank.png") center center / 40px 40px no-repeat;
}

.editor-tool-item[data-type="button"]::after {
	content: "";
	display: block;
	width: inherit;
	height: inherit;
	border: 2px solid transparent;
	position: absolute;
	left: 0;
	right: 0;
	top: 0;
	bottom: 0;
	z-index: 2;
}

.editor-tool-item[data-type="button"].active::after {
	border-color: #4C98A2;
}

.editor-tool-item[data-type="button"].disabled::after {
	border-color: transparent !important;
}

.editor-tool-item[data-type="range"] {
	display: block;
	width: 100%;
	height: 40px;
	padding: 0;
}

.editor-tool-item a {
	text-decoration: none;
	cursor: pointer;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-item[data-name="text"] {
	width: 100%;
	height: 70px;
	border: 1px solid rgba(0,0,0,0.1);
	font-weight: bold;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-item[data-name="font"] {
	height: 40px;
	border: 1px solid rgba(0,0,0,0.1);
	overflow: hidden;
	position: relative;
	background: #fff;
	cursor: pointer;
}

.editor-tool-item[data-name="font"]::before {
	content: '';
	display: block;
	width: 60px;
	height: 38px;
	margin: 1px;
	position: absolute;
	z-index: 1;
	top: 0;
	right: 0;
	background: linear-gradient(to right, rgba(255,255,255,0), rgba(255,255,255,1) 40%);
}

.editor-tool-item[data-name="font"]::after {
	display: block;
	content: "\e252";
	width: 40px;
	height: 40px;
	margin-top: -1px;
	position: absolute;
	right: 0;
	top: 0;
	z-index: 2;
	font: normal 14px/40px "Glyphicons Halflings";
	text-align: center;
}

.editor-tool-item[data-name="font"] img,
.editor-tool-item[data-name="font-select-box"] img {
	width: auto;
	height: 38px;
	vertical-align: bottom;
	/* opacity: 0.75; */
}

.editor-tool-item[data-name="font-select-box"] {
	position: absolute;
	left: 40px;
	right: 40px;
	bottom: 60px;
	z-index: 40;
	background: #fff;
}

.editor-tool-item[data-name="font-select-box"] ul {
	height: 400px;
	margin: 0;
	box-shadow: 0 -2px 15px rgba(0,0,0,0.2);
	overflow: auto;
	overflow-x: hidden;
	overflow-y: auto;
	list-style: none;
}

.editor-tool-item[data-name="font-select-box"] ul > li {
	height: 40px;
	border: 1px dashed transparent;
	margin: 0;
	padding: 0;
	overflow: hidden;
	cursor: pointer;
}

.editor-tool-item[data-name="font-select-box"] ul > li:not(:last-child) {
	border-bottom-color: rgba(0,0,0,0.08);
}

.editor-tool-item[data-name="font-select-box"] ul > li.active {
	background: #f7f7f7;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-item[data-name="spacing"]::before {
	background-image: url("/svg-editor/images/tools/spacing.svg");
	/* opacity: 0.75; */
}

.editor-tool-item[data-name="curve"]::before {
	background-image: url("/svg-editor/images/tools/curve.svg");
	/* opacity: 0.75; */
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-item[data-name^="paragraph-align-"]::before {
	/* opacity: 0.75; */
}

.editor-tool-item[data-name="paragraph-align-left"]::before {
	background-image: url("/svg-editor/images/tools/paragraph-align-left.svg");
}

.editor-tool-item[data-name="paragraph-align-center"]::before {
	background-image: url("/svg-editor/images/tools/paragraph-align-center.svg");
}

.editor-tool-item[data-name="paragraph-align-right"]::before {
	background-image: url("/svg-editor/images/tools/paragraph-align-right.svg");
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-group[data-name="appearance"] {}

.editor-tool-group[data-name="appearance"] .row {
	margin: 0 -10px;
}

.editor-tool-group[data-name="appearance"] .row > [class*="col-"] {
	width: auto;
	padding: 0 10px;
}

.editor-tool-item[data-name="fill"] {
	border: 0;
}

.editor-tool-item[data-name="fill"]::before {
	background-image: url("/svg-editor/images/tools/fill.svg");
}

.editor-tool-item[data-name="fill"].empty::before {
	background-image: url("/svg-editor/images/tools/fill-empty.svg");
}

.editor-tool-item[data-name="fill"].misc::before {
	background-image: url("/svg-editor/images/tools/fill-misc.svg");
}

.editor-tool-item[data-name="stroke"] {
	border: 0;
}

.editor-tool-item[data-name="stroke"]::before {
	background-image: url("/svg-editor/images/tools/stroke.svg");
}

.editor-tool-item[data-name="stroke"].empty::before {
	background-image: url("/svg-editor/images/tools/stroke-empty.svg");
}

.editor-tool-item[data-name="stroke"].misc::before {
	background-image: url("/svg-editor/images/tools/stroke-misc.svg");
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-group[data-name="transform"] {}

.editor-tool-group[data-name="transform"] .row {
	margin: 0 -5px;
}

.editor-tool-group[data-name="transform"] .row > [class*="col-"] {
	width: auto;
	padding: 0 5px;
}

.editor-tool-item[data-name="width"],
.editor-tool-item[data-name="height"] {
	width: 90px;
	border: 1px solid rgba(0,0,0,0.1);
	padding-left: 5px;
	padding-right: 5px;
	height: 40px;
	text-align: center;
}

.editor-tool-item[data-name="aspect-ratio-lock"] {
	font-size: 13px;
	line-height: 30px;
}

.editor-tool-item[data-name="aspect-ratio-lock"].text-primary {
	color: #4C98A2;
}

.editor-tool-item[data-name="aspect-ratio-lock"]:not(.text-primary) {
	color: inherit;
	opacity: 0.5;
}

.editor-tool-item[data-name="aspect-ratio-lock"] a {
	display: block;
	margin: 0 -10px;
	padding: 0 10px;
	position: relative;
	z-index: 1;
	color: inherit;
}

.editor-tool-item[data-name="aspect-ratio-lock"] span.glyphicon {
	height: 40px;
	position: relative;
	top: 0;
	line-height: 40px;
}

.editor-tool-group[data-name="transform"] [data-name="metrics"] {
	height: 40px;
	line-height: 40px;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-item[data-name^="align-"]::before {
	/* opacity: 0.75; */
}

.editor-tool-item[data-name="align-left"]::before {
	background-image: url("/svg-editor/images/tools/align-left.svg");
}

.editor-tool-item[data-name="align-center"]::before {
	background-image: url("/svg-editor/images/tools/align-center.svg");
}

.editor-tool-item[data-name="align-right"]::before {
	background-image: url("/svg-editor/images/tools/align-right.svg");
}

.editor-tool-item[data-name="align-top"]::before {
	background-image: url("/svg-editor/images/tools/align-top.svg");
}

.editor-tool-item[data-name="align-middle"]::before {
	background-image: url("/svg-editor/images/tools/align-middle.svg");
}

.editor-tool-item[data-name="align-bottom"]::before {
	background-image: url("/svg-editor/images/tools/align-bottom.svg");
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-group[data-name="arrange"] {}

.editor-tool-item[data-name="bring-forward"]::before {
	background-image: url("/svg-editor/images/tools/bring-forward.svg");
	/* opacity: 0.75; */
}

.editor-tool-item[data-name="send-backward"]::before {
	background-image: url("/svg-editor/images/tools/send-backward.svg");
	/* opacity: 0.75; */
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-popup {
	display: none;
	padding: 20px;
	position: absolute;
	left: 0;
	right: 0;
	top: 0;
	bottom: 0;
	z-index: 50;
	background: #f7f7f7;
	/* color: rgba(0,0,0,0.75); */
}

.editor-popup[data-name="fill"],
.editor-popup[data-name="stroke"] {
	border-bottom: 1px solid #e5e5e5;
	bottom: 110px;
}

.editor-popup-toggle {
	width: 40px;
	height: 40px;
	position: absolute;
	right: 0;
	top: 0;
	background: url("/svg-editor/images/controls/close.svg") 0 0 / 100% 100% no-repeat;
	cursor: pointer;
}

.editor-popup .editor-tool-group-heading {
	height: 20px;
	font-weight: bold;
	line-height: 1;
}

.editor-popup .editor-tool-group-content {
	margin-top: 20px;
}

.editor-popup .editor-tool-group-content::after {
	content: " ";
	display: table;
	width: 0;
	height: 0;
	clear: both;
}

.editor-popup .editor-tool-group .editor-tool-group + .editor-tool-group {
	margin-top: 30px;
}

.editor-popup .editor-tool-group[data-name="image"] .editor-tool-group-content {
	position: absolute;
	left: 20px;
	right: 20px;
	top: 40px;
	bottom: 20px;
}

.editor-popup .editor-tool-group[data-name="art"] .editor-tool-group-content {
	margin-top: 0;
	overflow-x: hidden;
	overflow-y: auto;
	position: absolute;
	left: 20px;
	right: 20px;
	top: 60px;
	bottom: 20px;
}

.editor-popup .minicolors {
	margin-right: 15px;
	float: left;
}

.editor-popup .minicolors .form-control.minicolors-field {
	width: 130px !important;
	height: 38px !important;
	padding-left: 40px !important;
	text-transform: uppercase;
}

.editor-popup .minicolors .form-control.minicolors-field + .minicolors-swatch {
	width: 28px;
	height: 28px;
	cursor: default;
}

.editor-popup .minicolors .minicolors-panel {
	display: block !important;
	margin-top: 30px;
	box-shadow: none;
}

.editor-popup .editor-tool-group[data-name="stroke-color"] + .editor-tool-group[data-name="stroke-width"] {
	margin-top: 220px;
}

.editor-popup .editor-tool-group[data-name="stroke-width"] .editor-tool-item[data-type="range"] {
	height: auto;
}

.editor-popup .editor-tool-group[data-name="available-threads"] .editor-tool-group-content {
	min-height: 25px;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-group[data-name="image"] [data-name="image"] {
	position: absolute;
	left: 0;
	right: 0;
	top: 0;
	bottom: 236px;
	/* background: rgba(0,0,0,0.03); */
}

.editor-tool-group[data-name="image"] [data-name="image-cover"] {
	display: flex;
	flex-flow: column;
	align-items: center;
	justify-content: center;
	position: absolute;
	inset: 0;
	text-align: center;
	opacity: 0.3;
}

.editor-tool-group[data-name="image"] [data-name="image-cover"] > strong {
	margin: 0 13%;
}

.editor-tool-group[data-name="image"] [data-name="image-cover"] > strong::before {
	content: "";
	display: block;
	width: 80px;
	height: 80px;
	margin: -30px auto 0;
	background: url("/svg-editor/images/controls/image.svg") center / 100% 100% no-repeat;
}

.editor-tool-group[data-name="image"] [data-name="image-preview"] {
	position: absolute;
	inset: 0;
}

.editor-tool-group[data-name="image"] [data-name="image-preview"] > a {
	display: block;
	position: absolute;
	inset: 0;
	cursor: zoom-in;
}

.editor-tool-group[data-name="image"] [data-name="image-preview"] > a > img {
	display: block;
	width: auto;
	max-width: 100%;
	height: auto;
	max-height: 100%;
	margin: auto;
	position: absolute;
	inset: 0;
	object-fit: contain;
}

.editor-tool-group[data-name="image"] [data-name="image-preview"] > span {
	display: none;
}

.editor-tool-group[data-name="image"] [data-name="image-preview"] > a.hidden + span {
	display: flex;
	align-items: center;
	justify-content: center;
	position: absolute;
	inset: 0;
	text-align: center;
	opacity: 0.3;
	cursor: wait;
}

.editor-tool-group[data-name="image"] [data-name="limit"] {
	padding: 2px 6px;
	position: absolute;
	right: 0;
	bottom: 236px;
	background: #ddd;
	color: #111;
	font-size: 10px;
	font-weight: bold;
	opacity: 0.6;
}

.editor-tool-group[data-name="image"][data-unavailable] [data-name="limit"] {
	background: #000;
	color: #fff;
	opacity: 1;
}

.editor-tool-group[data-name="image"] .input-group {
	width: 100%;
	position: absolute;
	left: 0;
	right: 0;
	bottom: 178px;
}

.editor-tool-group[data-name="image"] [data-name="prompt"] {
	height: 100px;
	position: absolute;
	left: 0;
	right: 0;
	bottom: 58px;
}

.editor-tool-group[data-name="image"] .btn-group {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
}

.editor-tool-group[data-name="image"] .btn-group button:not(:last-of-type) {
	margin-right: 15px;
}

/* ---------------------------------------------------------------------------------------------------- */

.editor-tool-item[data-name="thread-color"] {
	display: inline-block;
	width: 25px;
	height: 25px;
	position: relative;
	background: url("/i/others/chessboard.svg") 0 0 / 40% 40% repeat #fff;
	line-height: 1;
	vertical-align: bottom;
}

.editor-tool-item[data-name="thread-color"]:not(.current) {
	cursor: pointer;
}

.editor-tool-item[data-name="thread-color"].current::before {
	content: "";
	display: block;
	border: 1px solid #4C98A2;
	margin: -4px;
	position: absolute;
	left: 0;
	right: 0;
	top: 0;
	bottom: 0;
	z-index: 2;
}

.editor-tool-item[data-name="thread-color"]::after {
    content: "";
    display: block;
    border: 1px solid rgba(0,0,0,0.1);
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
    z-index: 1;
}

.editor-tool-group[data-name="threads"] .btn-group {
	float: left;
}

.editor-tool-group[data-name="threads"] .btn-group:not(:last-of-type) {
	margin-right: 10px;
}

.editor-tool-group[data-name="threads"] .btn-group > .btn.dropdown-toggle {
	border: 0 !important;
	padding: 0 !important;
	position: relative;
	z-index: 1 !important; /* Bootstrap fix */
	box-shadow: none !important;
	background: none !important;
}

.editor-tool-group[data-name="threads"] .btn-group > .btn.dropdown-toggle > * {
	float: left;
}

.editor-tool-group[data-name="threads"] .btn-group > .btn.dropdown-toggle > .caret {
	margin-left: 5px;
	position: relative;
	top: 11px;
}

.editor-tool-group[data-name="threads"] .btn-group > .dropdown-menu {
	width: 152px; /* 1 10 25 10 25 10 25 10 25 10 1 */
	min-width: 0;
	padding: 5px;
}

.editor-tool-group[data-name="threads"] .btn-group > .dropdown-menu[data-count="2"] {
	width: 82px;
}

.editor-tool-group[data-name="threads"] .btn-group > .dropdown-menu[data-count="3"] {
	width: 117px;
}

@media (max-width: 375px) {
	.editor-tool-group[data-name="threads"] .btn-group:nth-of-type(n+5) > .dropdown-menu {
		left: auto;
		right: 0;
	}
}

.editor-tool-group[data-name="threads"] .btn-group > .dropdown-menu > li {
	display: block;
	padding: 5px;
	float: left;
}

.editor-tool-item[data-name="thread-color-replacement"] {
	display: table;
	width: 87px; /* 25 23 25 5 8 + 1px fix */
	cursor: default;
}

.editor-tool-item[data-name="thread-color-replacement"]:not(:last-of-type) {
	margin-bottom: 13px;
}

.editor-tool-item[data-name="thread-color-replacement"] > * {
	float: left;
}

.editor-tool-item[data-name="thread-color-replacement"] > span {
	display: block;
	width: 23px;
	height: 25px;
	position: relative;
}

.editor-tool-item[data-name="thread-color-replacement"] > span::before {
	content: "";
	display: block;
	width: 7px;
	height: 13.3px;
	position: absolute;
	left: 50%;
	top: 50%;
	background: url("/i/shell/carousel-arrows.svg") right 0 / 200% 200% no-repeat;
	transform: translate(-50%, -50%);
}

.editor-tool-group[data-name="used-threads"] progress {
	margin-bottom: -2px;
	position: relative;
	top: -2px;
	z-index: 2;
}

.editor-tool-group[data-name="used-threads"] .row {
	margin: 0;
	padding: 15px;
	background: #fff;
}

.editor-tool-group[data-name="used-threads"] .row > [class*="col-"] {
	width: auto;
	padding: 0;
	float: none;
}

.editor-tool-group[data-name="used-threads"] .row > [class*="col-"]:first-child {
	position: absolute;
}

.editor-tool-group[data-name="used-threads"] .row > [class*="col-"]:last-child {
	padding-left: 101px; /* 86 + 15 */
}

.editor-tool-group[data-name="used-threads"] [data-name="threads-preview"] {
	height: 291px;
	overflow: hidden;
	position: relative;
}

.editor-tool-group[data-name="used-threads"] [data-name="threads-preview"] > svg {
	display: block;
	width: auto;
	max-width: 100%;
	height: auto;
	max-height: 100%;
	margin: 0 auto;
}

.editor-tool-group[data-name="used-threads"] button[data-name] {
	margin-top: 30px;
	float: left;
}

.editor-tool-group[data-name="used-threads"] button[data-name]:not(:last-child) {
	margin-right: 15px;
}

/* ---------------------------------------------------------------------------------------------------- */