
/* 
    Pop-ups Admin (deprecated)
*/

.column-greyd_popup_prio {
    user-select: none;
}
.column-greyd_popup_prio .popup_prio {
    display: inline-block;
    text-align: center;
    line-height: 11px;
    height: 14px;
    width: 14px;
    margin: 0px 3px;
    border-radius: 10px;
    cursor: pointer;
    background: #ddd;
}
.column-greyd_popup_prio .popup_prio.off {
    opacity: 0.5;
    cursor: not-allowed;
}
.column-greyd_popup_prio.blocked,
.column-greyd_popup_prio.blocked .popup_prio {
    cursor: wait;
}
body.post-type-greyd_popup #poststuff .postbox#popup_design .inside,
body.post-type-greyd_popup #poststuff .postbox#popup_settings .inside {
    margin: 0;
    padding: 0;
}
/* popup design */
.popup_design {
    display: flex;
    height: 550px;
    resize: vertical;
    overflow: hidden;
}
.popup_design_tabs {
    display: flex;
    flex-direction: column;
    width: 280px;
    border-right: 1px solid #ccc;
}
.popup_design_tabs .tabs {
    display: flex;
    overflow: hidden;
    background-color: #f5f5f5;
}
.popup_design_tabs .tabs .tablink {
    width: 100%;
    font-weight: 600;
    text-align: center;
    padding: 10px;
    color: #888;
    border-bottom: 1px solid #ccc;
    border-right: 1px solid #ccc;
    outline: none;
    cursor: pointer;
    transition: 0.3s;
}
.popup_design_tabs .tabs .tablink:last-child {
    border-right: 1px solid transparent;
}
.popup_design_tabs .tabs .tablink:hover {
    color: inherit;
    background-color: #eee;
}
.popup_design_tabs .tabs .tablink.active {
    color: inherit;
    background-color: #fff;
    border-bottom: 1px solid transparent;
}

.popup_design_tabs .tabcontent {
    flex: 1;
    display: none;
    padding: 0px 10px;
    border-top: none;
    overflow: auto;
    animation: fadeEffect 0.3s;
} 
@keyframes fadeEffect {
    from { opacity: 0; }
    to { opacity: 1; }
}
.popup_design_tabs .tabcontent.active {
    display: block;
}
.popup_design_tabs .tabcontent .input_section {
    margin: 35px 0px;
}

.popup_design_tabs .design_input {
    display: inline-block;
    width: 100%;
    margin-bottom: 20px;
}
.popup_design_tabs .design_input .head_label {
    display: inline-block;
    font-size: 18px;
    font-weight: 600;
    width: 100%;
    margin: 20px 0px;
    padding-top: 10px;
    border-top: 1px solid #ddd;
}
.popup_design_tabs .design_input:first-child .head_label {
    padding-top: 0px;
    margin-top: 0px;
    border-top: 0px solid #ddd;
}
.popup_design_tabs .design_input label {
    display: inline-block;
    margin-bottom: 3px;
    float: none !important;
    font-weight: 600;
}
.popup_design_tabs .design_input input,
.popup_design_tabs .design_input select {
    width: 100%;
}
.popup_design_tabs .design_input input[type="button"] {
    width: auto;
}
.popup_design_tabs .design_input input[type="checkbox"] {
    width: 1rem;
    margin-right: 5px;
}

.popup_design_tabs .design_input .shadow_setup,
.popup_design_tabs .design_input .shadow_color {
    width: 100% !important;
}
.popup_design_tabs .design_input .shadow_setup > div {
    flex-wrap: wrap;
    justify-content: space-between;
}
.popup_design_tabs .design_input .shadow_option,
.popup_design_tabs .design_input .shadow_type {
    width: calc(50% - 10px) !important;
}
.popup_design_tabs .design_input .shadow_preview {
    display: none !important;
}

.popup_design_tabs .design_input .grid_items > span {
    display: block;
    line-height: 0;
}
.popup_design_tabs .design_input .grid_items .input_item {
    display: inline-block;
    width: 20px;
    height: 20px;
    margin: 6px 6px 0 0;
    background: #f5f5f5;
    border: 1px solid #ccc;
    cursor: pointer;
    transition: 0.3s;
}
.popup_design_tabs .design_input .grid_items .input_item:hover {
    border-color: b1b1b1;
    background: #eee;
}
.popup_design_tabs .design_input .grid_items .input_item.active {
    border-color: #007cba;
    background: #007cba;
}

.popup_design_tabs .design_input .line_items,
#popup_settings .settings_input .line_items {
    display: flex;
}
.popup_design_tabs .design_input .line_items .input_item,
#popup_settings .settings_input .line_items .input_item {
    width: 100%;
    text-align: center;
    line-height: 27px;
    padding: 0px 15px;
    margin-top: 5px;
    background: #f5f5f5;
    border: 1px solid #ccc;
    cursor: pointer;
    transition: 0.3s;
}
#popup_settings .settings_input .line_items .input_item {
    background: #fff;
}
.popup_design_tabs .design_input .line_items .input_item:first-child,
#popup_settings .settings_input .line_items .input_item:first-child {
    border-top-left-radius: 5px;
    border-bottom-left-radius: 5px;
    border-right: 0px;
}
.popup_design_tabs .design_input .line_items .input_item:last-child,
#popup_settings .settings_input .line_items .input_item:last-child {
    border-top-right-radius: 5px;
    border-bottom-right-radius: 5px;
    border-left: 0px;
}
.popup_design_tabs .design_input .line_items .input_item:hover,
#popup_settings .settings_input .line_items .input_item:hover {
    background: #eee;
}
.popup_design_tabs .design_input .line_items .input_item.active,
#popup_settings .settings_input .line_items .input_item.active {
    color: #fff;
    border-color: #007cba;
    background: #007cba;
}
.popup_design_tabs .design_input .line_items .input_item.active[data-index="off"],
#popup_settings .settings_input .line_items .input_item.active[data-index="off"] {
    border-color: #575d65;
    background: #575d65;
}
.popup_design_tabs .design_input .descr {
    font-size: smaller;
    display: block;
    margin-top: 10px;
    line-height: 120%;
    color: #8c8c8c;
}



/* popup preview */
.popup_design .popup_design_preview {
    flex: 1;
    background: #e5e5e5;
    overflow: hidden;
    position: relative;
}
.popup_design .popup_design_preview .popup_website {
    position: absolute;
    height: 100%;
    width: 100%;
    pointer-events: none;
    overflow: hidden;
}
.popup_design .popup_design_preview .popup_website > iframe {
    height: 100%;
    width: 100%;
    transition: all 0.3s ease;
}
.popup_design .popup_design_preview .popup_switch {
    position: absolute;
    display: flex;
    bottom: 0;
    z-index: 100;
}
.popup_design .popup_design_preview .popup_switch .dashicons {
    width: 30px;
    height: 25px;
    line-height: 25px;
    font-size: 15px;
    color: #c9c9ca;
    background-color: #949495;
    transition: all 0.3s ease;
    cursor: pointer;
}
.popup_design .popup_design_preview .popup_switch .dashicons:hover,
.popup_design .popup_design_preview .popup_switch .dashicons.active {
    color: #fff;
    background-color: #575756;
}

/* popup preview basics */
#popup_preview.popup {
    display: flex;
    position: relative;
    width: 100%;
    height: 100%;
    z-index: 99;
    box-sizing: border-box;
    pointer-events: none;
}
#popup_preview.popup.hidden {
    display: none;
}
#popup_preview.popup .popup_overlay {
    position: absolute;
    width: 0; height: 0;
    z-index: -1;
    pointer-events: all;
}
#popup_preview.popup .popup_content {
    perspective: 1000px;
    transition: all 0.3s ease;
}
#popup_preview.popup .popup_content .popup_wrapper {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    transition: all 0.3s ease;
    pointer-events: all;
}

/* popup preview mobile */
.popup_design .popup_design_preview .popup_website,
#popup_preview.popup {
    transition: width .2s, margin-left .2s;
}
.popup_design .popup_design_preview .popup_website.mobile,
#popup_preview.popup.mobile {
/*
    width: calc(250px + 25%);
    margin-left: calc(37.5% - 125px);
*/
    width: 380px;
    margin-left: calc(50% - 190px)
}

/* popup close preview */
:root {
    --POPalign: left;
    --POPsize: 20px;
    --POPwidth: 2px;
    --POPcolor: #cfcfcf;
    --POPcolor_hover: #393d3d;
    --POPpadding: 0px;
    --POPborder_radius: 0px;
    --POPcolor_bg: transparent;
    --POPcolor_bg_hover: transparent;
    --backPOPcolor: #cfcfcf;
    --backPOPcolor_hover: #393d3d;
}
.popup_close_preview {
    text-align: var(--POPalign);
}
#popup_preview.popup .close_popup_wrapper,
.popup_close_preview .close_popup_wrapper {
    display: inline-block;
    text-align: left;
    width: var(--POPsize);
    height: var(--POPsize);
    padding: var(--POPpadding);
    border-radius: var(--POPborder_radius);
    background-color: var(--POPcolor_bg);
    cursor: pointer;
    box-sizing: content-box;
    transition: all 0.3s ease;
}
.popup_close_preview .close_popup_wrapper:hover {
    background-color: var(--POPcolor_bg_hover);
}
#popup_preview.popup .close_popup_wrapper .close_popup,
.popup_close_preview .close_popup_wrapper .close_popup {
    position: absolute;
}
#popup_preview.popup .close_popup_wrapper .close_popup:before, 
#popup_preview.popup .close_popup_wrapper .close_popup:after,
.popup_close_preview .close_popup_wrapper .close_popup:before, 
.popup_close_preview .close_popup_wrapper .close_popup:after {
    content: ' ';
    position: absolute;
    left: calc((var(--POPsize) - var(--POPwidth)) / 2);
    height: var(--POPsize);
    width: var(--POPwidth);
    background-color: var(--POPcolor);
    transition: all 0.3s ease;
}
.popup_close_preview .close_popup_wrapper:hover .close_popup:before, 
.popup_close_preview .close_popup_wrapper:hover .close_popup:after {
    background-color: var(--POPcolor_hover);
}
#popup_preview.popup .close_popup_wrapper .close_popup:before,
.popup_close_preview .close_popup_wrapper .close_popup:before {
    transform: rotate(45deg);
}
#popup_preview.popup .close_popup_wrapper .close_popup:after,
.popup_close_preview .close_popup_wrapper .close_popup:after {
    transform: rotate(-45deg);
}

#popup_preview.popup .right {
    text-align: right;
}
#popup_preview.popup .center {
    text-align: center;
}
#popup_preview.popup .close_popup_wrapper {
    width: 25px;
    height: 25px;
    padding: 0px;
    border-radius: 0px;
    background-color: transparent;
}
#popup_preview.popup .close_popup_wrapper .close_popup:before, 
#popup_preview.popup .close_popup_wrapper .close_popup:after {
    left: 11px;
    height: 25px;
    width: 2px;
    background-color: var(--backPOPcolor);
}
#popup_preview.popup .close_popup_wrapper:hover .close_popup:before, 
#popup_preview.popup .close_popup_wrapper:hover .close_popup:after {
    background-color: var(--backPOPcolor_hover);
}


/* popup settings */
#popup_settings .settings_input {
    width: 100%;
    max-width: 600px;
    margin-bottom: 10px;
    transition: 0.3s;
}
#popup_settings .settings_input
#popup_settings .settings_input .settings_options {
    margin-right: 25px;
}
#popup_settings .settings_input_switch {
    display: flex;
    align-items: center;
    min-height: 50px;
    width: 100%;
    /* max-width: 600px; */
    /* margin-top: 10px; */
    background: #f5f5f5;
    border: 1px solid #ddd;
    transition: 0.3s;
    box-sizing: border-box;
}
#popup_settings .settings_input_switch > .head_label {
    flex: 1 120px;
    margin-left: 20px;
    font-weight: 600;
    font-size: 14px;
}
#popup_settings .settings_input_switch > label {
    flex: 1 180px;
    display: flex;
    align-items: center;
    margin: 0px;
}
#popup_settings .settings_input_switch > label input {
    min-width: unset;
    width: 55px;
    margin: 0px 5px;
    padding-right: 0px;
}
#popup_settings .settings_input_switch > label input[type="number"] {
    width: 45px;
}

#popup_settings .settings_input .settings_input_switch > *:not(.settings_options):not(.greyd_switch) {
    transition: opacity 0.2s;
}
#popup_settings .settings_input.inactive .settings_input_switch > *:not(.settings_options):not(.greyd_switch) {
    opacity: 0.5;
}
#popup_settings .settings_input_switch .settings_options {
    margin-right: 20px;
}
#popup_settings .settings_input_switch .info_toggle {
    margin-right: 30px;
    cursor: pointer;
}
#popup_settings .settings_input_switch .greyd_switch {
    height: 40px;
    margin: 0px;
}
#popup_settings .settings_input_options {
    width: 100%;
    /* max-width: 600px; */
    padding: 20px 20px;
    background: #f5f5f5;
    border: 1px solid #ddd;
    border-top: none;
    box-sizing: border-box;
}
#popup_settings .settings_input_options.inline {
    display: flex;
    align-items: flex-end;
}
#popup_settings .settings_input_options.inline input:not([type="checkbox"]), 
#popup_settings .settings_input_options.inline select {
    min-width: unset;
}
#popup_settings .settings_input_options > label {
    display: block;
    margin-left: 20px;
    margin-right: 20px;
}
#popup_settings .settings_input_options .settings_input_option {
    display: flex;
    flex-direction: column;
    width: 100%;
}
#popup_settings .settings_input_options .head_label {
    font-size: 14px;
    margin-bottom: 10px;
}

#popup_settings .settings_input_element {
    display: flex;
    flex-direction: column;
    margin-bottom: 20px;
}
#popup_settings .settings_input_element select {
    max-width: 150px;
    margin-bottom: 5px;
}
#popup_settings .description_label {
    color: #868A8F;
    font-size: smaller;
    font-weight: normal;
}

#popup_settings .settings_input_options .tagarea {
    line-height: 2;
    min-height: 30px;
    padding: 0px 8px;
    margin-bottom: 15px;
    border-radius: 4px;
    border: 1px solid rgb(126, 137, 147);
    background-color: rgb(255, 255, 255);
    color: rgb(50, 55, 60);
    cursor: text;
    resize: vertical;
    overflow: auto;
}
#popup_settings .settings_input_options .tagarea .tag {
    display: inline-block;
    margin: 7px 5px 0px 0px;
    padding: 2px 8px;
    line-height: normal;
    border-radius: 4px;
    border: 1px solid #868A8F;
    background: #f5f5f5;
    color: #868A8F;
}
#popup_settings .settings_input_options .tagarea .tag .tag_close {
    cursor: pointer;
    padding-left: 5px;
    font-size: 18px;
    height: auto;
}
#popup_settings .settings_input_options .tagarea .tag .tag_close:hover {
    color: #007cba;
}
#popup_settings .settings_input_options .tagarea .tag_input {
    min-width: unset;
    border: 0;
    box-shadow: none;
}
#popup_settings .settings_input_options .tagarea .tag_suggestions {
    display: none;
    position: absolute;
    padding: 5px 15px;
    margin-top: -5px;
    min-width: 150px;
    max-height: 200px;
    overflow: auto;
    border-radius: 4px;
    border: 1px solid #868A8F;
    background: #f5f5f5;
    box-shadow: 0px 6px 12px rgba(0,0,0,0.175);
    z-index: 1000;
}
#popup_settings .settings_input_options .tagarea .tag_suggest {
    display: block;
    line-height: normal;
    padding: 1px 0px;
    color: #868A8F;
}
#popup_settings .settings_input_options .tagarea .tag_suggest.option {
    padding-left: 10px;
    color: inherit;
    cursor: pointer;
}
#popup_settings .settings_input_options .tagarea .tag_suggest.option:hover {
    color: #007cba;
}

/*
    Popups Gutenberg support
*/
body.post-type-greyd_popup.block-editor-page .edit-post-layout__metaboxes {
    background: #F0F0F0;
}
body.post-type-greyd_popup.block-editor-page .edit-post-layout__metaboxes .postbox {
    background: transparent;
}
body.post-type-greyd_popup.block-editor-page .edit-post-layout__metaboxes #poststuff .inside {
    background: #fff;
    border: 1px solid #ddd;
    margin: -1px 0 20px !important;
}