/* settings */
@blanco:        #FFF;
@gris:          #666;
@gris-claro-1:  #DDD;
@gris-claro-2:  #CCC;
@negro:         #333;
@naranja:       #F7805F;
@naranja-claro: #F2A083;

@space:         30px;
@line-height:   180%;
@border-radius: 3px;

.xowl-settings {
    line-height: @line-height;

    h1, h2, h3, h4, h5 {
        margin: 0px 0px @space 0px;
    }

    h3 {
        color: @negro;
    }

    h4 {
        font-size: 18px;
    }

    p {
        line-height: @line-height;
    }

    a {
        color: @naranja;
    }

    small {
        font-size: 12px;
        color: @gris;
    }

    input,
    button.button {
        height: 32px;
    }

    input {
        width: 300px;
        margin: 0px 10px @space / 2 0px;
        padding: 7px 15px;

        font-size: 12px;
        box-shadow: 0px 1px 0px rgba(255, 255, 255, 1) inset, 0px 1px 0px rgba(0, 0, 0, 0.15);
        border: 0px;
        border-radius: @border-radius;
        background-color: #EFFFEA;

        &:focus {
            border-color: transparent;
            box-shadow: 0px 1px 0px rgba(255, 255, 255, 1) inset, 0px 1px 0px rgba(0, 0, 0, 0.15);
        }
    }

    label {
        display: block;
        margin-bottom: 5px;

        font-weight: 700;
        color: @negro;
    }

    .button {
        font-size: 12px;
        text-transform: uppercase;
    }

    .text-right {
        text-align: right;
    }

    /* header */
    .xowl-header {
        position: relative;
        margin: 0px 20px @space * 1.5 0px;
        padding: 30px;

        background: url('../imgs/h2-back-2.png') no-repeat top right;
        background-color: @naranja;

        @media (max-width: 792px) {
            padding-bottom: 15px;
        }

        img.xowl-flower {
            position: absolute;
            top: 25px;
            left: 220px;
            height: 50px;
        }

        input.button-xowl-save-changes {
            height: auto;
            float: right;

            padding: 10px;
            line-height: 100%;

            @media (max-width: 792px) {
                display: block;
                float: none;
                width: 100%;
                margin-top: 20px;
            }
        }
    }

    /* content */
    .xowl-content {
        max-width: 660px;
        min-width: 320px;
        margin-right: 20px;
        overflow: hidden;

        @media (min-width: 792px) {
            padding-left: 20px;
        }
    }

    .xowl-step {
        position: relative;
        width: auto;
        margin-top: 30px;
        padding: 25px 0px 20px 0px;

        border-radius: @border-radius;
        border-bottom: 1px solid @gris-claro-1;

        h4 {
            margin-bottom: 10px;
        }

        p {
            margin: 0px 0px @space / 2 0px;
            color: @gris;
        }

        &:before {
            content: '';
            position: absolute;
            top: -5px;
            left: -10px;
            height: 27px;
            width: 30px;
            padding-top: 3px;

            font-size: 15px;
            font-weight: 700;
            color: @blanco;
            text-align: center;
            background-color: @naranja;
            border-radius: 50%;
            box-shadow: 0px 2px 2px @gris-claro-1;

            @media (max-width: 792px) {
                display: none;
            }
        }

        &.xowl-get-api {
            background-color: @gris-claro-1;

            &:before {
                content: '1';
            }
        }

        &.xowl-endpoint {
            background-color: @blanco;

            &:before {
                content: '2';
            }
        }

        &.xowl-active-api {
            background-color: @blanco;

            &:before {
                content: '3';
            }

            .xowl-active-api-check {
                content: '\f319';
                display: inline-block;
                width: 20px;
                height: 20px;
                font-size: 20px;
                line-height: 1;
                font-family: dashicons;
                text-decoration: inherit;
                font-weight: 400;
                font-style: normal;
                vertical-align: top;
                text-align: center;
                -moz-osx-font-smoothing: grayscale;
            }
        }

        &.xowl-step-disabled {
            opacity: 0.6;

            label,
            input,
            button {
                pointer-events: none;
                cursor: default;
            }
        }
    }

    .xowl-step-row {
        overflow: hidden;

        .xowl-step-left,
        .xowl-step-right {
            padding: 0px 30px;
        }

        .xowl-step-left {
            width: auto;
            float: left;
        }

        .xowl-step-right {
            width: auto;
            float: right;
        }
    }

    .xowl-check-step {
        .xowl-check-icon {
            display: none;
            float: right;
            margin: 6px 0px 0px 10px;
        }

        @media (max-width: 792px) {
            input,
            .button {
                display: block;
            }

            .xowl-check-icon {
                float: none;
                margin: 10px 0px 0px 0px;
            }
        }
    }
}

.xowl-demo {
    margin-top: @space * 2;

    h3 {
        margin-bottom: 0px;
    }
}

/* xowl editor */
/*.xowl-suggestion {
    cursor: pointer;
}*/

a[data-cke-type] {
    display: inline-block;
    margin: 0px 4px;
    padding: 0px 4px;

    border-radius: 1px;
    color: white;
    text-decoration: none;
    line-height: 1.2;
    cursor: pointer;

    &[data-cke-type="dPlace"]        {background-color: #43c35b;}
    &[data-cke-type="dPerson"]       {background-color: #e32e3f;}
    &[data-cke-type="dOrganisation"] {background-color: #d1ac2a;}
    &[data-cke-type="dProduct"]      {background-color: #c166d3;}
    &[data-cke-type="dWork"]         {background-color: #ff9985;}
    &[data-cke-type="others"]        {background-color: #5c9eda;}
}

a[data-cke-suggestions] {
    position: relative;

    &:before {
        content: attr(data-cke-suggestions);
        position: absolute;
        right: 0px;
        top: 0px;
        height: 1.5em;
        padding: 0px 4px;

        line-height: 1.6em;
        font-size: 65%;
        font-weight: bold;
        color: #888;
        background: #FFF;
        border: 1px solid #888;

        -moz-transform: translate(58%, -45%);
        -webkit-transform: translate(58%, -45%);
        -o-transform: translate(58%, -45%);
        -ms-transform: translate(58%, -45%);
        transform: translate(58%, -45%);
    }
}

a[data-xowl-selected] {
    &:before {
        color: #FFF;
        background: #8CAC1A;
        border: 1px solid #2B9B12;
    }
}

.xowl-loader {
    position: absolute;
    right: -50px;
    top: -50px;
    width: 100px;
    z-index: 1000;
    height: 100px;
    background-color: blue;
    transform: rotate(45deg);
}

.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: black;
    opacity: 0.5;
    z-index: 1000;

    img {
        position: fixed;
        left: 50%;
        top: 50%;
        width: 100px;
        margin-top:-50px;
        margin-left:-50px;
    }
}

.cke_editable {
    p {
        line-height: 1.8em;
    }
}