div[data-control-name="_form_fields"] {
	> .cx-control__content {
		flex: 0 0 100%;
	}
	.cx-ui-container.form-field-control:not(.cx-ui-repeater-container) {
		display: flex;
		padding: 15px 0;
		border-top: 1px solid rgba( 0,0,0, .1 );
		> label {
			max-width: 15%;
			flex: 0 0 15%;
			margin: 5px 0;
		}
		> .cx-ui-select-wrapper {
			display: flex;
			max-width: 100%;
			flex: 0 0 100%;
			> label {
				max-width: 15%;
				flex: 0 0 15%;
				margin: 5px 0;
			}
		}
	}
	._name-wrap .cx-ui-container.form-field-control {
		border-top: none;
		padding-top: 0;
	}

	._field_options-wrap {
		padding: 20px 0;
		border-top: 1px solid rgba( 0,0,0, .1 );
		.cheryr-ui-repeater-content-box {
			display: flex;
			justify-content: space-between;
			> div {
				width: 49%;
			}
		}
	}
	.form-field-child {
		display: none;
		&._type-active {
			display: block;
		}
		&._hidden_value-active {
			display: block;
		}
		&._field_options_from-active {
			display: block;
		}
	}
	.form-field-controls-list {
		> label {
			display: none;
		}
	}
}

div[data-control-name="_submit_label"],
div[data-control-name="_build_layout"] {
	> .cx-control__content {
		flex: 0 0 100%;
	}
}

#_build_layout {
	width: 100%;
	margin: 5px 0 0 0;
}

.jet-post-field-control {
	display: flex;
	padding: 3px 0 0 0;
	select {
		margin: 0 4px 0 0;
	}
	input {
		margin: 0;
	}
}


#form_builder,
#notifications_builder,
.notifications-builder {
	* {
		box-sizing: border-box;
	}
	.jet-form-canvas {
		&__field {
			background: #fafafa;
			padding: 8px 15px 8px;
			font-size: 14px;
			overflow: hidden;
			border: 1px solid #ddd;
			&-start {
				display: flex;
				align-items: center;
			}
			&-end {
				display: flex;
				align-items: center;
			}
			&-label {
				margin: 0 0 2px;
			}
			&-name {
				font-weight: bold;
				margin: 0 5px 0 0;
			}
			&-type {
				font-style: italic;
			}
			&-content {
				display: flex;
				justify-content: space-between;
				align-items: center;
				min-height: 100%;
			}
			&-remove {
				color: #a00;
				cursor: pointer;
				font-size: 18px;
				line-height: 20px;
				margin: 0 10px 0 0;
				&:hover {
					color: #dc3232;
				}
				&:before {
					content: "\f153";
					font-family: dashicons;
				}

				.rtl & {
					margin: 0 0 0 10px;
				}
			}
			&-edit {
				cursor: pointer;
				margin: 0 14px 0 15px;
				background: #0085ba;
				border: 1px solid;
				border-color: #0073aa #006799 #006799;
				box-shadow: 0 1px 0 #006799;
				color: #fff;
				text-decoration: none;
				text-shadow: 0 -1px 1px #006799, 1px 0 1px #006799, 0 1px 1px #006799, -1px 0 1px #006799;
				border-radius: 3px;
				height: 30px;
				width: 30px;
				display: flex;
				justify-content: center;
				color: #fff;
				align-items: center;
				&:hover {
					background: #008ec2;
					border-color: #006799;
				}
			}
		}
		&__actions {
			display: flex;
			justify-content: space-between;
			align-items: flex-start;
			padding: 5px 0 0 0;
			flex-wrap: wrap;
		}
		&__captcha {
			padding: 6px 0 0 0px;
			&-fields {
				flex: 0 0 100%;
				display: flex;
				flex-wrap: wrap;
				label {
					width: 350px;
					margin: 0 10px 0 0;

					.rtl & {
						margin: 0 0 0 10px;
					}

					input {
						width: 100%;
					}
				}
			}
			&-info {
				flex: 0 0 100%;
				padding: 10px 0 0 0;
			}
		}
		&__preset {
			margin: 10px 0 0 0;
			padding: 10px;
			background: #fafafa;
			border: 1px solid #ddd;
			&-heading {
				display: flex;
				align-content: center;
				margin: 0;
				input {
					margin: 1px 10px 0 0;

					.rtl & {
						margin: 1px 0 0 10px;
					}
				}
			}
			&-controls {
				padding: 10px 0 0 0;
			}
			&-row {
				padding: 10px 0;
				display: flex;
				border-bottom: 1px solid #ddd;
				align-items: flex-start;
				&:last-child {
					border-bottom: none;
				}
				> span {
					flex: 0 0 140px;
					max-width: 140px;
					display: block;
					padding: 6px 0 0 0;
				}
			}
		}
		&__buttons {
			display: flex;
		}
		&__result {
			height: 0;
			overflow: hidden;
			visibility: hidden;
		}
		&__add {
			cursor: pointer;
			background: #0085ba;
			border: 1px solid;
			margin: 0 0 0 10px;
			border-color: #0073aa #006799 #006799;
			box-shadow: 0 1px 0 #006799;
			color: #fff;
			text-decoration: none;
			text-shadow: 0 -1px 1px #006799, 1px 0 1px #006799, 0 1px 1px #006799, -1px 0 1px #006799;
			border-radius: 3px;
			width: 180px;
			display: flex;
			justify-content: center;
			font-size: 13px;
			line-height: 30px;
			padding: 0 15px;
			align-items: center;
			&:hover {
				background: #008ec2;
				border-color: #006799;
			}
			&.add-default {
				color: #555;
				border-color: #ccc;
				background: #f7f7f7;
				box-shadow: 0 1px 0 #ccc;
				text-shadow: none;
				&:hover {
					background: #fafafa;
					border-color: #999;
					color: #23282d;
				}
			}

			.rtl & {
				margin: 0 10px 0 0;
			}
		}
		.vue-grid-placeholder {
			background: #f00 !important;
			opacity: .2 !important;
		}

		.vue-grid-item {
			> .vue-resizable-handle {
				height: auto;
				top: 0;
				bottom: 0;
				background: rgba( 0,0,0,.05 );
				cursor: col-resize;
				display: flex;
				align-items: center;
				justify-content: center;
				padding: 0;
				border-left: 1px solid #ddd;
				&:before {
					content: "\f229";
					font-family: dashicons;
					opacity: .4;
				}
				.rtl & {
					left: 0;
					right: auto;
					border-left: none;
					border-right: 1px solid #ddd;
				}
			}
		}
	}

	.jet-form-list {
		&__item {
			background: #fafafa;
			padding: 15px;
			font-size: 14px;
			overflow: hidden;
			border: 1px solid #ddd;
			margin: 5px 0 0 0;
			.jet-form-editor {
				margin: 15px -16px -16px;
				background: #fff;
			}
			.jet-form-canvas__field-edit {
				margin: 0;
			}
		}
	}
}

#notifications_builder {
	overflow: hidden;
}

.notifications-builder {
	&.jet-form-list__item {
		position: relative;
		background: #fafafa;
		padding: 15px;
		font-size: 14px;
		overflow: hidden;
		border: 1px solid #ddd;
		margin: 5px 0 0 0;
		.jet-form-list__item-handle {
			position: absolute;
			width: 24px;
			height: 60px;
			left: 0;
			top: 0;
			background: #fefefe;
			border-right: 1px solid #ddd;
			display: flex;
			align-items: center;
			justify-content: center;
			cursor: ns-resize;
		}
		.jet-form-editor {
			margin: 15px -16px -16px;
			background: #fff;
		}
		.jet-form-canvas__field-edit {
			margin: 0;
		}
	}
	.jet-form-canvas {
		&__field {
			&-content {
				padding: 0 0 0 20px;
			}
			&-notice {
				color: #a00;
			}
		}
	}
}

.jet-form-editor {
	margin: 10px 0 0;
	border: 1px solid #ddd;
	padding: 20px;
	&__header {
		background: #f5f5f5;
		padding: 15px 20px;
		margin: -20px -20px 10px -20px;
		border-bottom: 1px solid #ddd;
		font-weight: bold;
		font-size: 16px;
	}
	&__args {
		&-list {
			margin: 0 0 5px;
		}
	}
	&__input {
		&-icon {
			position: relative;
			input[type="text"] {
				padding-right: 35px;
			}
		}
		&-open-popup {
			position: absolute;
			right: 1px;
			top: 1px;
			width: 30px;
			height: 30px;
			line-height: 30px;
			color: #007cba;
			cursor: pointer;
			&:hover {
				color: #444;
			}
		}
		&-popup {
			position: fixed;
			z-index: 999;
			top: 0;
			right: 0;
			left: 0;
			bottom: 0;
			display: none;
			align-items: center;
			justify-content: center;
			&.is-active {
				display: flex;
			}
			&-content {
				background: #fff;
				width: 500px;
				padding: 30px;
				z-index: 2;
			}
			&-overlay {
				position: absolute;
				top: 0;
				right: 0;
				bottom: 0;
				left: 0;
				z-index: 1;
				background: rgba( 0, 0, 0, .7 );
			}
		}
	}
	&__callbacks {
		&-list {
			display: flex;
		}
		&-item {
			margin: 0 4px 0 0;
			border: 1px solid #0071a1;
			color: #0071a1;
			border-radius: 3px;
			padding: 2px 7px 4px;
			line-height: 13px;
			font-size: 13px;
			cursor: pointer;
			&:hover {
				border-color: #016087;
				color: #016087;
			}
		}
	}
	&__group {
		padding: 10px 0 10px;
		margin: 0 0 0 20px;
		display: flex;
		border-bottom: 1px solid #eee;
		&:last-child {
			border-bottom: none;
		}
	}
	&__col {
		flex: 0 0 auto;
		margin: 0 5px;
		&-label {
			padding: 0 0 5px;
			i {
				color: #999;
			}
		}
	}
	&__row {
		padding: 10px 0;
		display: flex;
		min-height: 50px;
		box-sizing: border-box;
		border-top: 1px solid #ddd;
		&:first-child {
			border-top: none;
		}
		&.direction-column {
			flex-direction: column;
		}
		&-title {
			font-weight: bold;
		}
		&-label {
			max-width: 250px;
			width: 250px;
			padding: 5px 0;
			&.fullwidth-label {
				width: 100%;
				max-width: 100%;
			}
		}
		input[type="checkbox"] {
			margin: 5px 0 0 0;
		}
		input[type="text"],
		textarea,
		select {
			width: 400px;
			.messages-list & {
				width: 600px;
			}
		}
		textarea {
			height: 250px;
		}
		&-control {
			&-desc {
				display: inline-block;
				margin: 0px 0 0 10px;
				font-style: italic;
				vertical-align: bottom;
			}
		}
		&-notice {
			padding: 5px 5px 5px 0;
			font-size: 13px;
			opacity: 0.7;
		}
		&-error {
			padding: 0 5px 5px 0;
		}
		&-map {
			display: flex;
			align-items: center;
			span {
				width: 150px;
			}
			input[type="text"] {
				width: 250px;
			}
		}
	}
	&__actions {
		background: #f5f5f5;
		padding: 15px 20px;
		margin: 10px -20px -20px -20px;
		border-top: 1px solid #ddd;
		display: flex;
		justify-content: space-between;
	}

	&__input-group {
		display: flex;
		flex-wrap: wrap;
		margin: 0 -5px;

		> * {
			margin: 0 5px;
		}
	}
}

.jet-form-repeater {
	max-width: 600px;
	&__item {
		display: flex;
		justify-content: space-between;
		align-items: stretch;
		padding: 0;
		background: #fafafa;
		border: 1px solid #ddd;
		border-top: none;
		&:first-child {
			border-top: 1px solid #ddd;
		}
		&:last-child {
			margin-bottom: 10px;
		}
		&-input {
			display: flex;
			align-items: center;
			width: 31%;
			&-label {
				padding: 5px 10px;
				white-space: nowrap;
			}
			input[type="text"] {
				width: 100px;
				box-sizing: border-box;
				margin: 0;
				padding: 5px;
				border-top: none;
				border-bottom: none;
				border-radius: 0;
				border-color: #ddd;
				line-height: 1.4;
			}
		}
		&-delete {
			width: 7%;
		}
		.dashicons.dashicons-dismiss {
			cursor: pointer;
			background: #a00;
			color: #fff;
			width: 100%;
			height: calc( 100% + 2px);
			margin: -1px -1px -1px 0;
			border: 1px solid darken( #a00, 5% );
			padding: 4px 0 0 0;
			text-align: center;
			&:hover {
				background: #dc3232;
			}
		}
	}
}

.jet-form-validate-button.button,
.jet-form-load-button.button {
	display: inline-flex;
	align-items: center;

	i {
		margin-right: 4px;

		.rtl & {
			margin-left: 4px;
			margin-right: 0;
		}
	}

	&.loading i {
		animation: jet-form-editor-spin 2s infinite linear;
	}
}

.jet-form-validate-button.button {
	i.dashicons {
		&:before {
			content: "\f463";
		}
	}

	&.is-valid i.dashicons {
		&:before {
			content: "\f147";
			color: #46b450;
		}
	}

	&.is-invalid i.dashicons {
		&:before {
			content: "\f335";
			color: #a00;
		}
	}
}

@keyframes jet-form-editor-spin {
	0% {
		transform: rotate(0deg);
	}
	100% {
		transform: rotate(359deg);
	}
}

.jet-engine-gateways-row {
	padding: 5px 0;
	&__label {
		display: block;
		margin: 0 0 5px;
	}
	select,
	input[type="text"],
	textarea {
		width: 630px;
	}
}

.jet-engine-gateways-section {
	padding: 15px 0;
	&__title {
		font-size: 16px;
		line-height: 23px;
		font-weight: bold;
	}
}

.jet-engine-gateways-group {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	border-bottom: 1px solid #ddd;
	padding: 0 0 15px;
	margin: 0 0 10px;
	&__title {
		flex: 0 0 100%;
		margin: 0 0 10px;
		padding: 15px 0 0 0;
		font-size: 16px;
		line-height: 23px;
		font-weight: bold;
	}
	&__item {
		width: 32%;
		flex: 0 0 32%;
		&-title {
			font-weight: bold;
			font-style: italic;
			padding: 0 0 5px;
		}
	}
}

.jet-engine-gateways-macros-list {
	&__title {
		font-weight: bold;
		padding: 0 0 5px;
	}

	ul {
		padding: 0 0 10px;
		margin: 0;
		li {
			font-style: italic;
		}
	}
}
