.clearfix() {
    &:after {
        clear: both;
        content: "";
        display: table;
    }
}

th.col-form-name { width: 25%; }
th.col-form-shortcode { width: 25%; }

th.col-form-entries,
th.col-form-views,
th.col-form-conversion { width: 10%; }

th.col-entry-id {
    width: 5%;
}
th.col-entry-details {
    width: 10%;
}

table.wpuf-contact-form {
    td, th {
        vertical-align: top;
    }
}

.wpuf-form-builder-field-options .panel-field-opt {

    &.panel-field-name {
        > label {
            display: block;
            clear: both;
        }

        .name-field-placeholder,
        .name-field-value {
            float: left;
            width: 48%;

            label {
                font-size: 10px;
            }
        }

        .name-field-placeholder {
            margin-right: 4%;
        }
    }
}

.wpuf-contact-form-entry-wrap {
    margin-top: 20px;
    width: 100%;
    overflow: hidden;

    .wpuf-contact-form-entry-left {
        float: left;
        width: 70%;

        &.weforms-quiz-entry {
            .field-points{
                float: right;
            }

            .field-value{
                &.right-answer{
                    background: #dff0d8;
                }

                &.wrong-answer{
                    background: #FFE4E4;
                }
            }
        }
    }

    .wpuf-contact-form-entry-right {
        float: right;
        width: 28%;
    }

    h2.hndle {
        padding: 8px 12px;
        margin: 0;
        font-size: 14px;
    }

    table.widefat {
        border: none
    }

    .button .dashicons {
        margin-top: 4px;
    }
}

.postboxes {

    &.two-col {
        display: flex;
        flex-wrap: wrap;
        width: 100%;

        .postbox {
            width: 48%;
            display: flex;
            flex-direction: column;

            &:nth-child(2n+1) {
                margin-right: 3%;
            }

            &:nth-child(2n+2) {
                margin-right: 0;
            }
        }

        .submit-wrapper {
            margin-top: auto;
            text-align: right;
            padding-right: 10px;
            border-top: 1px solid #eee;
            padding-top: 10px;
            background: #fafafa;
            padding-bottom: 10px;
        }
    }
}

.export-import-wrap {

    select.forms-list {
        min-width: 300px;
    }

    .loading-spinner {
        float: none;
        display: block;
        margin: 0 auto;
        margin-top: 20px;
    }

    .upload-status .spinner {
        float: none;
        display: inline-block;
        margin: 0;
        background-size: 18px 18px;
    }
}

.weforms-premium {

    .wp-badge {
        background: #40ce65 url(../images/weforms-pro.png) no-repeat;
        background-size: 100px 90px;
        background-position: 35px 5px;
    }

    .weforms-upgrade-sticky-footer {
        position: fixed;
        bottom: 0;
        background: #fff;
        width: ~"calc(100% - 195px)";
        z-index: 9;
        margin-left: -25px;
        text-align: center;
        border: 1px solid #dfdfdf;
        padding: 20px 0;
        border-bottom: none;
    }

    .four-col .col {
        -webkit-align-self: flex-start;
        -ms-flex-item-align: start;
        align-self: flex-start;
        min-width: 23%;
        max-width: 23%;
    }
}

a.add-notification .dashicons {
    margin-top: 4px;
}

.notification-wrap {
    width: 100%;
    overflow: hidden;
    display: block;
    margin-top: 20px;

    .notification-row.notification-field .mce-tinymce{
        border: 1px solid #ddd;

        .mce-i-shortcode::before{
            font-family: dashicons;
            content: "\f475";
        }
    }

    .notification-table-wrap {
        width: 100%;

        table.wpuf-cf-notification-table {
            width: 70%;
            transition: width 0.3s ease-in-out;

            .col-toggle {
                width: 35px;
            }

            .col-name {
                width: 35%;

                a {
                    font-weight: bold;
                }
            }

            .col-action {
                width: 15%;
            }
        }
    }

    .notification-edit-area {
        background: #fff;
        border: 1px solid #e5e5e5;
        box-shadow: 0 1px 1px rgba(0,0,0,0.04);
        margin-bottom: 30px;
        display: none;

        a {
            text-decoration: none;
        }

        .notification-head {
            padding: 8px 10px;
            background: #f9f9f9;
            border-bottom: 1px solid #e1e1e1;
            margin-bottom: 15px;

            input {
                width: 100%;
                padding: 8px;
            }
        }

        .form-fields {
            padding: 8px 10px;

            input, textarea {
                width: 100%;
                padding: 6px 25px 6px 6px;
            }

            input[type='radio'] {
                 width: auto;
            }

            .notification-row {
                margin-bottom: 10px;
                position: relative;
                .clearfix();
            }

            .row-one-half {
                float: left;
                width: 48%;
                position: relative;

                &.first {
                    margin-right: 4%;
                }
            }

            label {
                display: block;
                padding-bottom: 5px;
            }

            .advanced-field-wrap {
                display: none;
            }

            .notification-conditional-logic{

                .help{
                    margin-bottom: 0px;
                }

                .condition-status{
                    margin-bottom: 0px;
                    margin-top: 8px;
                }

                .condiotional-logic-repeater{
                    margin: 8px 0px;
                }
            }
        }

        .submit-area {
            padding: 8px 10px;
            background: #f9f9f9;
            border-top: 1px solid #e1e1e1;
            margin-top: 5px;
            .clearfix();

            .button {
                float: right;
            }
        }
    }

    &.editing {
        .notification-table-wrap {
            width: 40%;
            float: left;

            table.wpuf-cf-notification-table {
                .col-toggle,
                .col-subject,
                .col-action {
                    display: none;
                }
            }
        }

        .notification-edit-area {
            float: right;
            width: 60%;
            display: block;
        }
    }
}

/* Make clicks pass-through */
#nprogress {
    pointer-events: none;

    .bar {
        background: #29d;

        position: fixed;
        z-index: 1031;
        top: 0;
        left: 0;

        width: 100%;
        height: 2px;
    }

    /* Fancy blur effect */
    .peg {
        display: block;
        position: absolute;
        right: 0px;
        width: 100px;
        height: 100%;
        box-shadow: 0 0 10px #29d, 0 0 5px #29d;
        opacity: 1.0;

        -webkit-transform: rotate(3deg) translate(0px, -4px);
                -ms-transform: rotate(3deg) translate(0px, -4px);
                        transform: rotate(3deg) translate(0px, -4px);
    }

    /* Remove these to get rid of the spinner */
    .spinner {
        display: block;
        position: fixed;
        z-index: 1031;
        top: 15px;
        right: 15px;
    }

    .spinner-icon {
        width: 18px;
        height: 18px;
        box-sizing: border-box;

        border: solid 2px transparent;
        border-top-color: #29d;
        border-left-color: #29d;
        border-radius: 50%;

        -webkit-animation: nprogress-spinner 400ms linear infinite;
                        animation: nprogress-spinner 400ms linear infinite;
    }
}

.nprogress-custom-parent {
    overflow: hidden;
    position: relative;

    #nprogress {
        .spinner,
        .bar {
            position: absolute;
        }
    }
}

.weforms-modules {
    margin-top: 15px;
    overflow: hidden;

    .plugin-card {
        border: 1px solid #e5e5e5;
        box-shadow: 0 1px 1px rgba(0,0,0,0.04);

        .plugin-name {
            color: #0073aa;
        }

        .desc,
        .name {
            margin-left: 115px;
        }

        .plugin-card-top {
            min-height: 105px;
        }

        .plugin-icon {
            width: 96px;
            height: 96px;
            margin: 0 20px 0px 0;
        }
    }

    .activate-deactivate-all{
        margin-top: 15px;

        a {
            text-decoration: none;
        }
    }
}

.weforms-help-page {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    margin-top: 30px;

    * {
        box-sizing: border-box;
    }

    .help-block {
        flex: 1;
        align-self: flex-start;
        min-width: 31%;
        max-width: 32%;
        border: 1px solid #ddd;
        margin-right: 2%;
        margin-bottom: 25px;
        border-radius: 3px;
        padding: 25px 15px;
        text-align: center;
        background: #fff;

        &:hover {
            background: #f9f9f9;
        }

        img {
            max-height: 70px;
        }
    }
}

@-webkit-keyframes nprogress-spinner {
    0%   { -webkit-transform: rotate(0deg); }
    100% { -webkit-transform: rotate(360deg); }
}
@keyframes nprogress-spinner {
    0%   { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes color-me-in {
  /* You could think of as "step 1" */
  0% {
    background: orange;
  }
  /* You could think of as "step 2" */
  100% {
    background: black;
  }
}


@keyframes weFormsZoomIn {
    from {
        opacity: 0;
        transform: scale3d(.3, .3, .3);
    }

    50% {
        opacity: 1;
    }
}

@keyframes weFormsFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.wefroms-form-templates .wpuf-form-template-modal{

    .choose-form-categroy{
        float: right;
        font-size: 14px;
        margin-right: 70px;
        font-weight: normal;
    }

    .content{

        h2{
            font-size: 15px;
            color: #5d6d74;
            width: 100%;
        }

        max-width: 985px;

        ul li:nth-child(3n+1) {
            margin-left: 3.0612244897959% !important;
            clear: none !important;
        }

        ul li:nth-child(4n+1) {
            margin-left: 0 !important;;
            clear: both !important;;
        }

        .blank-form .blank-form-text{
            margin-top: 70px;
            font-size: 15px;

            .title{
                color: rgb(146, 146, 146);
            }
        }
    }


    .content ul li {
        text-align: center;
        min-height: 280px;
        width: 220px;
        border: 0px;
        box-shadow: 1px 2px 5px rgba(0,0,0,0.1);
        position: relative;
        border-radius: 3px;

        img{
            width: 100%;
        }

        .form-create-overlay{
            position: absolute;
            display: none;
        }

        &:hover {

            background: #fff;

            .form-create-overlay{
                animation: weFormsFadeIn .25s;
                padding: 10px;
                text-align: center;
                display: flex;
                flex-direction: column;
                justify-content: center;
                background: rgba(0, 0, 0, 0.7);
                height: 100%;
                width: 100%;
                top: 0px;
                left: 0px;
                color: #fff;
                border-radius: 3px;

                .title {
                    color: #fff;
                }
                .description {
                    color: #fff;
                }

                button{
                    height: 30px;
                }
            }
        }

        h3 {
            margin-top: 0px;
            border: 0px;
            background: #1E87B6;
            padding: 13px;
            font-weight: normal;
            font-size: 13px;
            color: #fff;
            border-radius: 3px 3px 0px 0px;
            text-align: left;
        }

        &.template-inactive h3{
            background: #ccc;
        }
    }
}

.ann-form-btn{
    background: rgb(231, 76, 60) !important;
}
.ann-form-btn.sharing_on{
    background: rgb(39, 174, 96) !important;
}

.weforms-single-product-price-warp{

    display: table;

    span {
        padding: 6px 12px;
        font-size: 14px;
        font-weight: 400;
        line-height: 1;
        color: #555;
        text-align: center;
        background-color: #eee;
        border: 1px solid #ddd;
        border-radius: 4px;
        border-top-right-radius: 0;
        border-bottom-right-radius: 0;
        width: 1%;
        white-space: nowrap;
        vertical-align: middle;
        display: table-cell;
        border-right: 0px;
    }

    input {
        display: table-cell;
        width: 99%;
        margin: 0px;
    }
}

#weforms-settings {

    height: 100%;

    #weforms-settings-tabs-warp {

        margin-top: 15px;
        margin-bottom: 15px;
        box-shadow: 0px 0px 5px rgba(0, 0, 0, 0.15);
        background: #fff;
        border-radius: 2px;
        display: flex;

        &.weforms-pro-deactivate{
            width: 75%;
            float: left;
        }

        #weforms-settings-tabs {
            background: #f1f1f1;
            min-width: 220px;

            border-radius: 2px;
            margin: 0;
            padding: 0;
            border-bottom: 0px;
            border-top-right-radius: 0px;
            border-bottom-right-radius: 0px;

            border-right: 1px solid #e5e5e5;

            ul {

                list-style-type: none;
                padding: 0;
                margin: 0;
                min-height: 200px;

                li {

                    margin: 0;
                    padding: 0;

                    a {
                        display: block;
                        padding: 13px 25px;
                        text-decoration: none;
                        color: #444;
                        border: 0px;
                        transition: 0s;

                        border-bottom: 1px solid #e5e5e5;

                        margin-right: 0px;

                        img {
                            width: 20px;
                            margin-right: 10px;
                            vertical-align: middle;
                            max-height: 20px;
                        }

                        &.we-settings-nav-tab-active{
                          background: #fff;
                        }
                    }

                    &:last-child a {
                        border-bottom: 0;

                        &.we-settings-nav-tab-active{
                          border-bottom: 1px solid #e5e5e5;
                        }
                    }

                    &:focus,  a:focus{
                        outline: 0;
                        -webkit-box-shadow: none;
                        box-shadow: none;
                    }
                }


            }
        }

        #weforms-settings-tabs-contents {
            width: 100%;
            padding-left: 0px;
            margin-left: 0px;

            .tab-content{
                min-height: 500px;
            }

            .inside{
                padding: 0px 20px;

                .form-table{
                    clear: right;
                }
            }

            h3.hndle {
                border-bottom: 1px solid #eff4f6;
                padding-left: 24px;
                margin: 0px;
            }

            .submit-wrapper {
                border-top: 1px solid #eff4f6;
                margin-top: 10px;
            }

            .submit-wrapper, h3.hndle{
                padding: 14.5px 20px;
            }
        }
    }

    #weforms-settings-page-sidebar{
        width: 25%;
        display: inline-block;
        padding-left: 15px;
        box-sizing: border-box;

        .weforms-settings-page-sidebar-content{
            background: #fff;
            padding: 15px 15px 50px 15px;
            margin-top: 15px;
            box-shadow: 0px 0px 5px rgba(0, 0, 0, 0.15);
            border-radius: 2px;

            h2 {
                margin-top: 0;
                font-size: 20px;
                line-height: 26px;
            }

            ul{
                li{
                    margin-bottom: 20px;
                    padding-left: 30px;
                    position: relative;

                    span{
                        &.dashicons{
                            color: #fff;
                            background: #58B99D;
                            border-radius: 50%;
                            position: absolute;
                            left: 0;
                            top: 2px;
                        }
                    }
                }
            }
        }
    }
}

.wpuf-integrations-wrap .wpuf-integration .wpuf-integration-header .wpuf-integration-header-label img.icon{
    width: 24px;
}

.weforms-field-mapping-custom {
    table {

        td{
            min-width: 300px;
            vertical-align: top;
        }

        select, input {
            width: 100%;
        }

        .fa-minus-circle{
            color: #000;
        }

        .remove{
            margin-top: 5px;
            margin-left: 5px;
            display: inline-block;
        }

        .custom-field-input{
            input{
                width: 90%;
                float: right;
            }
        }
    }

    .wpuf-int-form-row::before,
    .wpuf-int-form-row::after{
        display: inline-block !important;
    }

    a.merge-tag-link {
        margin-top: -1px;
    }

    button.add {
        margin-top: 10px;
        margin-left: 5px;
    }
}

.wpuf-contact-form-entries{
    .subsubsub{
        a.current, a:focus{
            box-shadow: none;
        }
    }
}

.field-text-with-tag {
    position: relative;
}

.name-merge-tag-holder {
    position: relative;

    .wpuf-merge-tag-wrap .merge-tag-link{
        top: 3px;
    }

    .wpuf-merge-tag-wrap .wpuf-merge-tags{
        top: 27px;
    }
}

th.weforms-form-status-col-title{
    text-align: center;
}

td.weforms-form-status{
    text-align: center;
}

td.weforms-form-status p{
    font-size: 12px;
    font-weight: 700;
    margin: 0;
}

td.weforms-form-status span{
    display: block;
    font-style: italic;
    font-size: 10px;
    margin-left: 8px;
    margin-bottom: 0;
}

td.weforms-form-status span.weforms-status-closed{
  color: red;
}

.weforms-form-status .open{
  color: #3aa73a;
}

.contact-form-list th.col-form-shortcode{
  width: 170px;
}

.contact-form-list th.col-form-entries,
.contact-form-list th.col-form-views{
  width: 50px;
}

.contact-form-list th.col-form-conversion{
  width: 80px;
}

td.weforms-form-creator img{
  max-width: 30px;
  border-radius: 50%;
  float: left;
  margin-right: 8px;
  margin-top: 4px;
}

td.weforms-form-creator span{
  text-transform: capitalize;
  display: block;
}

td.weforms-form-creator span.date{
  font-size: 10px;
}

label{
    &.weforms-switch{
        position: relative;
        display: block;
        padding-left: 20px;
        margin-bottom: 5px;
        margin-top: 5px;

        input[type=checkbox]{
            opacity: 0;
            width: 0;
            height: 0;
        }

        .switch-slider {
          position: absolute;
          cursor: pointer;
          top: 0;
          left: 0;
          right: 0;
          bottom: 0;
          background-color: #ccc;
          -moz-transition: .4s;
          -webkit-transition: .4s;
          transition: .4s;
          width: 35px;
          height: 18px;
        }

        .switch-slider:before {
            position: absolute;
            content: "";
            height: 14px;
            width: 14px;
            left: 3px;
            bottom: 2px;
            background-color: white;
            -moz-transition: .4s;
            -webkit-transition: .4s;
            transition: .4s;
        }

        input:checked + .switch-slider {
          background-color: #8DC63F;
        }

        input:checked + .switch-slider:before {
          -webkit-transform: translateX(16px);
          -ms-transform: translateX(16px);
          transform: translateX(16px);
        }

        /* Rounded sliders */
        .switch-slider.round {
          border-radius: 34px;
        }

        .switch-slider.round:before {
          border-radius: 50%;
        }
    }
}

ul.wpuf-form{
    .wpuf-field-columns{
        padding: 0;
        border: 0;
        overflow: hidden;

        &.has-columns-1{
            .wpuf-column{
                .wpuf-column-inner-fields{
                    width: 100%;
                    float: left;

                    &:nth-child(1){
                        padding-right: 0!important;
                    }
                }

                .column-1{
                    .ui-resizable-handle{
                        display: none !important;
                    }
                }

                .column-2.wpuf-column-inner-fields,
                .column-3.wpuf-column-inner-fields{
                    display: none;
                }
            }
        }

        &.has-columns-2{
            .wpuf-column{
                .wpuf-column-inner-fields{
                    width: 50%;
                    float: left;

                    &:nth-child(2){
                        padding-right: 0!important;
                    }
                }

                .column-2{
                    .ui-resizable-handle{
                        display: none !important;
                    }
                }

                .column-3.wpuf-column-inner-fields{
                    display: none;
                }
            }
        }

        &.has-columns-3{
            .wpuf-column{
                .wpuf-column-inner-fields{
                    width: 33.33%;
                    float: left;

                    &:nth-child(3){
                        padding-right: 0!important;
                    }
                }
            }
        }

        .wpuf-column-field-inner-columns{
            margin-left: 0;
            margin-right: 0;

            .wpuf-column{
                padding: 0;
                border: 0;
                float: none;
                width: 100%;
                display: flex;

                .wpuf-column-inner-fields{
                    padding: 0 5px 0 0;
                    position: relative;

                    ul.wpuf-column-fields-sortable-list{
                        border: 1px dashed #ffb900;
                        background: rgba(255, 185, 0, 0.08);
                        margin: 0;
                        padding: 0 0 50px 0;

                        li.column-field-items{
                            background: #fff;
                            -webkit-box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
                            box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);

                            &.current-editing{
                                background-color: rgba(255, 185, 0, 0.15);
                            }

                            &:last-child{
                                margin-bottom: 0;
                            }

                            &:hover .wpuf-column-field-control-buttons{
                                display: block;
                            }

                            .wpuf-column-field-control-buttons{
                                position: absolute;
                                top: 0;
                                left: 0;
                                z-index: 10;
                                display: none;
                                width: 100%;
                                height: 100%;
                                margin: 0;
                                text-align: center;
                                background: rgba(255, 185, 0, 0.08);
                                border: 1px dashed #ffb900;

                                p{
                                    position: absolute;
                                    top: 50%;
                                    left: 50%;
                                    margin: -10px 0 0 -43px;
                                    line-height: 1;
                                    color: #eee;
                                    background-color: #23282d;
                                }

                                i{
                                    cursor: pointer;
                                    padding: 5px;
                                    font-size: 10px;

                                    &:hover{
                                        background-color: #0073aa;
                                    }

                                    &.move{
                                        cursor: move;
                                    }
                                }
                            }
                        }
                    }
                    .drop-message{
                        text-align: center;
                        border: 1px dashed #ffb900;
                        border-top: 0;
                        background: rgba(255, 185, 0, 0.08);
                        margin: 0;
                        padding: 15px 0;
                    }
                }
            }
        }
    }
}

#form-preview-stage .field-items .wpuf-field-columns + div.control-buttons{
    top: 10px;
    z-index: 10;
    height: auto;
    margin: 0;
    background: transparent;
    border: 0;
}

@import './premium.less';
@import './integration.less';