// ------------------------------------------------------------------------------------
// XTS METABOXES
// ------------------------------------------------------------------------------------

.xts-metaboxes {
	@extend %xts-checkbox;

	// .xts-fields-tabs {
	// 	flex-direction: column;
	// }

	.inside & {

		.xts-fields-wrapper {
			margin-top: -7px;
			margin-right: -10px;
			margin-bottom: -45px;
			margin-left: -10px;
		}

		.xts-sections {
			padding-right: 10px;
			padding-left: 10px;
			width: 100%;
		}

		.xts-tabs {

			&.xts-style-default {
				margin-right: -27px;
				margin-left: -27px;

				> div {

					&:first-child {
						padding-left: 24px;
					}

					&:last-child {
						padding-right: 24px;
					}
				}
			}
		}

		.xts-last-tab-field {
			margin-right: -27px;
			margin-left: -27px;

			.xts-option-title {
				padding-left: 27px;
			}

			.xts-option-control {
				padding-right: 24px;
				padding-left: 10px;
			}
		}
	}

	.xts-group-title {
		margin-right: -12px;
		margin-left: -12px;
		padding-left: 27px;
		padding-right: 27px;

		&:first-child {
			margin-top: 1px;
			border-top-width: 0;
		}
	}

	.edit-post-layout__metaboxes & {

		.xts-group-title {
			margin-right: -14px;
			margin-left: -14px;
			padding-left: 29px;
			padding-right: 29px;

			&:first-child {
				margin-top: 0 !important;
				border-top-width: 1px;
			}
		}
	}

	.xts-sections-nav,
	.xts-section-title {
		display: none;
	}

	.xts-set-btn-img {
		flex-basis: auto;
		max-width: 200px;
	}
}

#addtag,
#edittag,
.product_page_product_attributes form {

	.xts-metaboxes {
		margin-top: 30px;
		margin-bottom: 30px;
	}

	.xts-sections {
		overflow: hidden;
		padding-top: 30px;
	}

	.xts-field {
		flex-wrap: wrap;

		.xts-option-title {
			margin-bottom: 0;
			padding-bottom: 0;
			width: 100%;
			border-bottom: 0;

			label {
				margin-bottom: 0;
			}
		}

		.xts-field-description {
			margin-top: 5px;
		}

		.xts-option-control {
			margin-top: 15px;
			padding-bottom: 25px;
		}

		.xts-range-slider {
			margin-top: 0 !important;
		}

		&:not(:last-child) {
			margin-bottom: 25px;
		}
	}
}

// ------------------------------------------------------------------------------------------------
// RTL
// ------------------------------------------------------------------------------------------------

.rtl {

	.inside {

		.xts-metaboxes {

			.xts-tabs {

				&.xts-style-default {

					> div {

						&:first-child {
							// padding-left: 0;
							padding-right: 24px;
						}

						&:last-child {
							padding-right: 0;
							padding-left: 24px;
						}
					}
				}
			}

			.xts-last-tab-field {

				.xts-option-title {
					padding-right: 27px;
					padding-left: 0;
				}

				.xts-option-control {
					padding-right: 10px;
					padding-left: 24px;
				}
			}
		}
	}
}