[class*="htmega"],
[class*="htmega"]::before,
[class*="htmega"]::after,
[class*="htmega"] *,
[class*="htmega"] *::before,
[class*="htmega"] *::after {
    box-sizing: border-box;
}

/*
 * Common Style
 */
.htmega-panel-control .components-panel__body-toggle.components-button:focus {
    box-shadow: none;
}
.htmega-panel-control .components-panel__body.is-opened {
    padding-top: 0;
    padding-bottom: 20px;
}
.htmega-panel-control .components-panel__body.is-opened .components-panel__body-title {
    margin-top: 0;
    margin-bottom: 16px;

    background-color: #EDEDED;
}
.htmega-panel-control .components-base-control:not(:last-child) {
    margin-bottom: 15px;
}
.htmega-popover-control .components-base-control:not(:last-child) {
    margin-bottom: 10px;
}
.htmega-panel-control .components-base-control:last-child,
.htmega-popover-control .components-base-control:last-child {
    margin-bottom: 0;
}
.htmega-popover-control-wrapper .components-base-control .components-base-control__field,
.htmega-panel-control .components-base-control .components-base-control__field {
    margin-bottom: 0;
    padding: 0;
}
.htmega-panel-control .components-base-control:last-child,
.htmega-panel-control .components-base-control:last-child {
    margin-bottom: 0;
}
.htmega-component-label,
.components-toggle-control__label,
.htmega-popover-control-wrapper .htmega-component-label,
.htmega-panel-control .components-base-control .components-base-control__label,
.htmega-panel-control .components-toggle-control .components-toggle-control__label {
    font-size: 11px;
    font-weight: 500;
    line-height: 1.4;

    display: block;
    display: flex;
    align-items: center;

    margin-bottom: 8px;
    padding: 0;

    text-transform: uppercase;
}
.components-toggle-control__label,
.components-toggle-control .components-toggle-control__label,
.components-flex-item .components-input-control__label,
.components-select-control .components-input-control__label,
.htmega-popover-control-wrapper .htmega-popover-control .htmega-component-label,
.htmega-panel-control .htmega-popover-control .htmega-component-label,
.htmega-panel-control .components-base-control.components-toggle-control .components-toggle-control__label,
.htmega-panel-control .components-base-control.htmega-popover-control .components-base-control__label {
    margin-bottom: 0;
}
.htmega-popover-control-wrapper .htmega-panel-row-height-auto,
.htmega-panel-control .htmega-panel-row-height-auto {
    height: auto;
    min-height: auto;
}


/*
 * Inspector Tab Control Style
 */
.htmega-control-tab-menu-item {
    flex: 1 0;
    justify-content: center;

    padding: 3px 10px;

    white-space: nowrap;

    gap: 3px;
}
.htmega-control-tab-menu-item:focus:not(:disabled),
.htmega-control-tab-menu-item.is-primary:focus:not(:disabled) {
    outline: none;
    box-shadow: none;
}

.htmega-panel-control .components-color-palette__custom-color {
    height: 30px;
    padding: inherit;

    background-position: 0 0,15px 15px;
    background-size: 30px 30px;
}

/**
 * Responsive Switcher Button Component
 */
.htmega-panel-control .htmega-responsive-control {
    position: relative;

    width: 24px;
    height: 24px;
    margin-left: 5px;
}
.htmega-panel-control .htmega-responsive-control:not(.open-switcher) {
    overflow: hidden;
}
.htmega-panel-control .htmega-responsive-control-buttons {
    position: absolute;
    z-index: 20;

    background: #FFFFFF;
}
.htmega-panel-control .htmega-responsive-control.open-switcher .htmega-responsive-control-buttons {
    box-shadow: 0 0 0 1px #A4AFB7;
}
.htmega-panel-control .htmega-responsive-control-buttons .components-button {
    width: 100%;
    min-width: inherit;
    height: 24px;
    padding: 0;

    border: 0;
    border-radius: 0;
    box-shadow: none;
}
.htmega-panel-control .htmega-responsive-control-buttons .components-button:focus:not(:disabled) {
    outline: none;
    box-shadow: none;
}
.htmega-panel-control .htmega-responsive-control-buttons .components-button .dashicon {
    font-size: 14px;
    line-height: 20px;

    margin: 0;
}

/*
 * Column Control
 */
.htmega-panel-control .htmega-column-control {
    justify-content: flex-start;

    min-height: auto;
}

/*
 * Toggle Control
 */
.htmega-popover-control-wrapper .components-toggle-control .components-flex,
.htmega-panel-control .components-toggle-control .components-flex {
    flex-direction: row-reverse;
}
.htmega-popover-control-wrapper .components-form-toggle .components-form-toggle__input:focus + .components-form-toggle__track,
.htmega-panel-control .components-form-toggle .components-form-toggle__input:focus + .components-form-toggle__track {
    box-shadow: none;
}

/*
 * Range Control
 */
.htmega-popover-control-wrapper .components-range-control__tooltip {
    top: -80%;
    bottom: auto;
}

/*
 * Popover Style
 */
.htmega-popover-control-wrapper .components-popover__content {
    width: 248px;
    padding: 10px;
}
.htmega-popover-control-wrapper .components-popover__content .components-base-control {
    margin-bottom: 15px;
}
.htmega-popover-control-wrapper .components-popover__content .components-base-control:last-child {
    margin-bottom: 0;
}
.htmega-panel-control .htmega-popover-control .htmega-button-group {
    gap: 4px;
}
.htmega-popover-control-wrapper .htmega-popover-toggle,
.htmega-panel-control .htmega-popover-toggle {
    position: relative;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 27px;
    min-width: auto;
    height: 27px;
    padding: 0;

    border-radius: 3px;
    background-color: #E3E3E3;
}
.htmega-popover-control-wrapper .htmega-popover-toggle-reset,
.htmega-panel-control .htmega-popover-toggle-reset {
    background-color: transparent;
}
.htmega-popover-control-wrapper .htmega-popover-toggle-color::before,
.htmega-popover-control-wrapper .htmega-popover-toggle-color::after,
.htmega-popover-control-wrapper .htmega-popover-toggle-gradient::before,
.htmega-popover-control-wrapper .htmega-popover-toggle-gradient::after,
.htmega-panel-control .htmega-popover-toggle-color::before,
.htmega-panel-control .htmega-popover-toggle-color::after,
.htmega-panel-control .htmega-popover-toggle-gradient::before,
.htmega-panel-control .htmega-popover-toggle-gradient::after {
    position: absolute;
    top: 5px;
    left: 5px;

    width: 17px;
    height: 17px;

    content: "";

    border-radius: 3px;
}
.htmega-popover-control-wrapper .htmega-popover-toggle-color::before,
.htmega-popover-control-wrapper .htmega-popover-toggle-gradient::before,
.htmega-panel-control .htmega-popover-toggle-color::before,
.htmega-panel-control .htmega-popover-toggle-gradient::before {
    z-index: 2;

    background-image: url("data:image/svg+xml;utf8, <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 2 2\"><path fill=\"white\" d=\"M1,0H2V1H1V0ZM0,1H1V2H0V1Z\"/><path fill=\"gray\" d=\"M0,0H1V1H0V0ZM1,1H2V2H1V1Z\"/></svg>");
    background-size: 7px;
}
.htmega-popover-control-wrapper .htmega-popover-toggle-color::after,
.htmega-panel-control .htmega-popover-toggle-color::after {
    z-index: 3;

    background-color: var(--color);
}
.htmega-popover-control-wrapper .htmega-popover-toggle-gradient::after,
.htmega-panel-control .htmega-popover-toggle-gradient::after {
    z-index: 3;

    background-image: var(--gradient);
}
.htmega-popover-control-wrapper .htmega-popover-toggle:focus:not(:disabled),
.htmega-panel-control .htmega-popover-toggle:focus:not(:disabled) {
    outline: none;
    box-shadow: none;
}

/*
 * Repeater Control
 */
.htmega-panel-control .htmega-repeater-control:not(:last-child) {
    margin-bottom: 10px;
}
.htmega-panel-control .htmega-repeater-control-head {
    position: relative;

    display: flex;

    padding: 10px;

    cursor: pointer;

    border: 1px solid #D5DADF;
}
.htmega-panel-control .htmega-repeater-control-remove {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 100%;
    max-width: 40px;
    height: 100%;

    cursor: pointer;

    border-left: 1px solid #D5DADF;
}
.htmega-panel-control .htmega-repeater-control-remove:focus:not(:disabled) {
    outline: none;
    box-shadow: none;
}
.htmega-panel-control .htmega-repeater-control-body {
    padding: 10px;

    border-width: 0 1px 1px;
    border-style: solid;
    border-color: #D5DADF;
}
.htmega-panel-control .htmega-repeater-control-body:not(.htmega-repeater-control-active) {
    display: none;
}
.htmega-panel-control .htmega-repeater-control-body .components-base-control:not(:last-child) {
    margin-bottom: 10px;
}

/*
 * Media Control
 */
.htmega-panel-control .htmega-media-control {
    position: relative;
}
.htmega-panel-control .htmega-media-control .editor-post-featured-image__toggle,
.htmega-panel-control .htmega-media-control .editor-post-featured-image__preview {
    min-height: 90px;

    border-radius: 2px;
    background-color: #F0F0F0;
}
.htmega-panel-control .htmega-media-control .editor-post-featured-image__toggle:focus:not(:disabled),
.htmega-panel-control .htmega-media-control .editor-post-featured-image__preview:focus:not(:disabled) {
    outline: none;
    box-shadow: none;
}
.htmega-panel-control .htmega-media-control-remove {
    height: auto;
    margin-top: 3px;
    padding: 0;

    text-decoration: underline;

    border: none;
    box-shadow: none !important;
}

/*
 * Text Control
 */
.htmega-panel-control .components-base-control .components-text-control__input:focus:not(:disabled) {
    outline: none;
    box-shadow: none;
}

/*
 * Color Control (Color Plate)
 */
.htmega-panel-control .htmega-color-control .components-base-control__field > .components-flex {
    flex-direction: row;
    justify-content: flex-start;
}
.htmega-panel-control .htmega-color-control .components-dropdown {
    flex: 1 0;
}
.htmega-panel-control .htmega-color-control .components-color-palette__custom-color-wrapper {
    flex-direction: row;
    justify-content: flex-start;

    gap: 0;
}
.htmega-panel-control .htmega-color-control .components-color-palette__custom-color-button {
    width: 60px;
    height: 60px;
}
.htmega-panel-control .htmega-color-control .components-color-palette__custom-color-button:focus:not(:disabled) {
    box-shadow: inset 0 0 0 1px rgba(0,0,0,0.2);
}
.htmega-panel-control .htmega-color-control .components-color-palette__custom-color-text-wrapper {
    flex: 1 0;

    padding: 10px;

    box-shadow: inset -1px 0 0 rgba(0,0,0,0.2), inset 0 1px 0 rgba(0,0,0,0.2), inset 0 -1px 0 rgba(0,0,0,0.2);

    gap: 4px;
}
.htmega-panel-control .htmega-color-control .components-circular-option-picker {
    width: auto;
    min-width: auto;
}

/* Color Picker */
.htmega-popover-control-wrapper .components-color-picker,
.htmega-popover-control-wrapper .components-color-picker .react-colorful {
    width: 100%;
}
.htmega-popover-control-wrapper .components-color-picker > *:last-child {
    display: flex;
    flex-direction: column;

    padding: 0 16px 10px;

    gap: 10px;
}
.htmega-popover-control-wrapper .components-color-picker > *:last-child > * {
    padding: 0;
}
.htmega-popover-control-wrapper .components-color-picker .components-base-control {
    margin-bottom: 0;
}

/*
 * Link Control
 */
.htmega-panel-control .htmega-link-control .components-base-control.htmega-popover-control {
    margin-bottom: 8px;
}

/*
 * Dimensions Control
 */
.htmega-popover-control-wrapper .htmega-dimensions-control .htmega-component-label,
.htmega-panel-control .htmega-dimensions-control .htmega-component-label {
    margin-bottom: 0;
}
.htmega-popover-control-wrapper .htmega-dimensions-control-units-choices,
.htmega-panel-control .htmega-dimensions-control-units-choices {
    margin-left: auto;
}
.htmega-popover-control-wrapper .htmega-dimensions-control-units-choices span,
.htmega-panel-control .htmega-dimensions-control-units-choices span {
    font-size: 10px;

    padding: 0 3px;

    cursor: pointer;
    text-transform: uppercase;

    color: #A4AFB7;
}
.htmega-popover-control-wrapper .htmega-dimensions-control-units-choices span.unit-active,
.htmega-panel-control .htmega-dimensions-control-units-choices span.unit-active {
    text-decoration: underline;

    color: #6D7882;
}
.htmega-popover-control-wrapper .htmega-dimensions-control .htmega-dimensions-control-head,
.htmega-panel-control .htmega-dimensions-control .htmega-dimensions-control-head {
    justify-content: flex-start;
}
.htmega-popover-control-wrapper .htmega-dimensions-control .components-base-control.components-input-control,
.htmega-panel-control .htmega-dimensions-control .components-base-control.components-input-control {
    margin-bottom: 0;
}
.htmega-popover-control-wrapper .htmega-dimensions-control .components-panel__row:not(.htmega-dimensions-control-head) .components-button.has-icon,
.htmega-panel-control .htmega-dimensions-control .components-panel__row:not(.htmega-dimensions-control-head) .components-button.has-icon {
    align-self: flex-start;

    width: 30px;
    min-width: auto;
    height: 30px;

    color: #A4AFB7;
    box-shadow: inset 0 0 0 1px #A4AFB7;
}
.htmega-popover-control-wrapper .htmega-dimensions-control .components-button.has-icon.is-primary,
.htmega-panel-control .htmega-dimensions-control .components-button.has-icon.is-primary {
    color: #FFFFFF !important;
    border-color: #A4AFB7;
    background-color: #A4AFB7;
}
.htmega-popover-control-wrapper .htmega-dimensions-control .components-button:focus:not(:disabled),
.htmega-panel-control .htmega-dimensions-control .components-button:focus:not(:disabled) {
    outline: none;
    box-shadow: inset 0 0 0 1px #A4AFB7;
}
.htmega-popover-control-wrapper .htmega-dimensions-control .components-number-control .components-flex,
.htmega-panel-control .htmega-dimensions-control .components-number-control .components-flex {
    gap: 5px;
}
.htmega-popover-control-wrapper .htmega-dimensions-control .components-number-control .components-input-control__input,
.htmega-panel-control .htmega-dimensions-control .components-number-control .components-input-control__input {
    padding-right: 0;
}
.htmega-popover-control-wrapper .htmega-dimensions-control .components-number-control .components-input-control__backdrop,
.htmega-panel-control .htmega-dimensions-control .components-number-control .components-input-control__backdrop {
    border-color: #A4AFB7;
    border-right: none;
    border-radius: 0 !important;
}
.htmega-popover-control-wrapper .htmega-dimensions-control .components-number-control .components-input-control__label,
.htmega-panel-control .htmega-dimensions-control .components-number-control .components-input-control__label {
    font-size: 10px;

    margin: 0;
}

/*
 * Group Tabs Control
 */
.htmega-group-tabs-control {
    margin-bottom: 10px;
}
.htmega-group-tabs-control:last-child {
    margin-bottom: 0;
}
.htmega-panel-control .htmega-group-tabs-menu {
    display: flex;
    flex-wrap: wrap;

    margin-bottom: 15px;
}
.htmega-panel-control .htmega-group-tabs-menu .htmega-group-tabs-menu-btn {
    font-weight: 500;

    flex: 1 0;
    justify-content: center;

    color: #222222;
    box-shadow: inset 0 0 0 1px #A4AFB7;
}
.htmega-panel-control .htmega-group-tabs-menu .htmega-group-tabs-menu-btn:hover {
    color: #222222;
    box-shadow: inset 0 0 0 1px #A4AFB7;
}
.htmega-panel-control .htmega-group-tabs-menu .htmega-group-tabs-menu-btn.is-primary {
    color: #FFFFFF;
    background-color: #A4AFB7;
    box-shadow: inset 0 0 0 1px #A4AFB7;
}
.htmega-panel-control .htmega-group-tabs-menu .htmega-group-tabs-menu-btn.is-primary:focus:not(:disabled) {
    outline: none;
    box-shadow: none;
}

/* Icon Control */
.htmega-icon-control-icon-wrapper {
    display: grid;

    gap: 4px;
    grid-template-columns: repeat(5, 1fr);
}
.htmega-icon-control-icon-wrapper .components-button {
    align-items: center;
    justify-content: center;

    height: auto;
    padding: 10px 6px;

    border: 1px solid #DDDDDD;
}
.htmega-icon-control-icon-wrapper .components-button.active {
    background-color: #DDDDDD;
}
.htmega-icon-control-icon-wrapper .components-button:focus {
    outline: none;
    box-shadow: none;
}
.htmega-icon-control-icon-wrapper .components-button span {
    font-size: 18px;

    width: auto;
    height: auto;
}
.htmega-icon-control-footer {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: space-between;

    margin-top: 10px;
}
.htmega-icon-control-footer [class*="htmega-arrow"] {
    cursor: pointer;
}
.htmega-icon-control-footer .htmega-arrow-next.disable,
.htmega-icon-control-footer .htmega-arrow-prev.disable {
    cursor: default;
    pointer-events: none;

    opacity: 0.5;
}
.htmega-icon-not-found-text {
    font-style: italic;

    text-align: center;
}

/* Tag Button Control */
.htmega-tag-button-group {
    display: flex;
}
.htmega-tag-button-group .components-button {
    flex: 1 0;
    justify-content: center;

    height: 30px;
    padding: 5px;

    box-shadow: inset 0 0 0 1px #E6E7E9;
}
.htmega-tag-button-group .components-button:focus:not(:disabled) {
    outline: none;
    box-shadow: inset 0 0 0 1px var(--wp-admin-theme-color);
}

/* Alignment Control */
.components-alignment-control .htmega-alignment-btn-group {
    display: flex;
    flex-wrap: wrap;
}
.components-alignment-control .htmega-alignment-btn-group .components-button {
    flex: 1 0;

    height: auto;

    color: #7C7C7C;
    box-shadow: inset 0 0 0 1px #A4AFB7;
}
.components-alignment-control .htmega-alignment-btn-group .components-button:hover:not(:disabled) {
    box-shadow: inset 0 0 0 1px #A4AFB7;
}
.components-alignment-control .htmega-alignment-btn-group .components-button:focus:not(:disabled) {
    box-shadow: inset 0 0 0 1px #A4AFB7;
}
.components-alignment-control .htmega-alignment-btn-group .components-button.is-primary,
.components-alignment-control .htmega-alignment-btn-group .components-button.is-primary:hover {
    color: #FFFFFF;
    background-color: #A4AFB7;
    box-shadow: inset 0 0 0 1px #A4AFB7;
}


/* Styling Information */
.htmega-inspector-style-info {
    display: block;

    margin-top: 20px;
    padding: 10px 15px;

    border-left: 5px solid rgba(14,202,240, 0.35);
    background-color: rgba(14,202,240, 0.15);
}
.htmega-inspector-style-info p {
    margin: 0;
}


/* Inspector Section Heading */
.htmega-control-section-title-area {
    position: relative;
    z-index: 1;

    margin-bottom: 10px;
}
.htmega-control-section-title {
    font-weight: 700;

    padding-right: 5px;

    background-color: #FFFFFF;
}
.htmega-control-section-title-area hr {
    position: absolute;
    z-index: -1;
    top: 50%;
    left: 0;

    width: 100%;
    margin: 0;
}
