@import "../start";

$form_width: 480px;

#fs_connect
{
    width:  $form_width;
    @include box-shadow(0px 1px 2px rgba(0, 0, 0, 0.3));
    margin: 20px 0;

    @media screen and (max-width: ($form_width - 1)) {
        @include box-shadow(none);
        width:                    auto;
        margin:                   0 0 0 -10px;
    }

    .fs-content
    {
        background: #fff;
        padding:    15px 20px;

        .fs-error {
            background: snow;
            color: $fs-logo-magenta-color;
            border: 1px solid $fs-logo-magenta-color;
            @include box-shadow(0 1px 1px 0 rgba(0,0,0,.1));
            text-align: center;
            padding: 5px;
            margin-bottom: 10px;
        }

        p
        {
            margin:    0;
            padding:   0;
            font-size: 1.2em;
        }
    }

    .fs-license-key-container {
        position: relative;
        width: 280px;
        margin: 10px auto 0 auto;

        input {
            width: 100%;
        }

        .dashicons {
            position: absolute;
            top: 5px;
            right: 5px;
        }
    }

    &.require-license-key {
        .fs-sites-list-container {
            td {
                cursor: pointer;
            }
        }
    }

    #delegate_to_site_admins {
        margin-right: 15px;
        float: right;
        height: 26px;
        vertical-align: middle;
        line-height: 37px;
        font-weight: bold;
        border-bottom: 1px dashed;
        text-decoration: none;

        &.rtl {
            margin-left: 15px;
            margin-right: 0;
        }
    }

    .fs-actions
    {
        padding:    10px 20px;
        background: #C0C7CA;

        .button
        {
            padding:       0 10px 1px;
            line-height:   35px;
            height:        37px;
            font-size:     16px;
            margin-bottom: 0;

            .dashicons
            {
                font-size:    37px;
                margin-left:  -8px;
                margin-right: 12px;
            }

            &.button-primary
            {
                padding-right: 15px;
                padding-left:  15px;

                &:after
                {
                    content: ' \279C';
                }

                &.fs-loading
                {
                    &:after
                    {
                        content: '';
                    }
                }
            }

            &.button-secondary
            {
                float: right;
            }
        }

        //        .fs-skip
        //        {
        //            line-height: 38px;
        //            vertical-align: middle;
        //            text-decoration: none;
        //            margin-left: 10px;
        //        }
    }

    &.fs-anonymous-disabled
    {
        .fs-actions
        {
            .button.button-primary
            {
                width: 100%;
            }
        }
    }

    .fs-permissions
    {
        padding:    10px 20px;
        background: #FEFEFE;
        //        background: #F1F1F1;
        @include transition(background 0.5s ease);

        .fs-license-sync-disclaimer {
            text-align: center;
            margin-top: 0;
        }

        .fs-trigger
        {
            font-size:       0.9em;
            text-decoration: none;
            text-align:      center;
            display:         block;
        }

        ul
        {
            height:   0;
            overflow: hidden;
            margin:   0;

            li
            {
                margin-bottom: 12px;

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

                i.dashicons
                {
                    float:     left;
                    font-size: 40px;
                    width:     40px;
                    height:    40px;
                }

                div
                {
                    margin-left: 55px;

                    span
                    {
                        font-weight:    bold;
                        text-transform: uppercase;
                        color:          #23282d;
                    }

                    p
                    {
                        margin: 2px 0 0 0;
                    }
                }
            }
        }

        &.fs-open
        {
            background: #fff;

            ul
            {
                height: auto;
                margin: 20px 20px 10px 20px;
            }
        }

        @media screen and (max-width: ($form_width - 1)) {
            background:               #fff;

            .fs-trigger
            {
                display: none;
            }

            ul
            {
                height: auto;
                margin: 20px;
            }
        }
    }

    .fs-freemium-licensing {
        padding: 8px;
//        background: #0085BA;
        background: #777;
        color: #fff;

        p {
            text-align: center;
            display: block;
            margin: 0;
            padding: 0;
        }

        a {
            color: #C2EEFF;
            text-decoration: underline;
        }
    }

    $icon_size: 80px;
    $wp_logo_padding: $icon_size / 10;
    $icons_top: 10px;

    .fs-visual
    {
        padding:     12px;
        line-height: 0;
        background:  #fafafa;
        height:      $icon_size;
        position:    relative;

        .fs-site-icon
        {
            position: absolute;
            left:     20px;
            top:      $icons_top;
        }

        .fs-connect-logo
        {
            position: absolute;
            right:    20px;
            top:      $icons_top;
        }

        .fs-plugin-icon
        {
            position:    absolute;
            top:         $icons_top;
            left:        50%;
            margin-left: - ($icon_size / 2);
        }

        .fs-plugin-icon,
        .fs-site-icon,
        img,
        object
        {
            width:  $icon_size;
            height: $icon_size;
        }

        .dashicons-wordpress
        {
            font-size:  $icon_size - ($wp_logo_padding * 2);
            background: $wordpress_color;
            color:      #fff;
            width:      $icon_size - ($wp_logo_padding * 2);
            height:     $icon_size - ($wp_logo_padding * 2);
            padding:    $wp_logo_padding;
        }

        .dashicons-plus
        {
            position:   absolute;
            top:        50%;
            font-size:  30px;
            margin-top: -10px;
            color:      #bbb;

            &.fs-first
            {
                left: 28%;
            }
            &.fs-second
            {
                left: 65%;
            }
        }

        .fs-plugin-icon,
        .fs-connect-logo,
        .fs-site-icon
        {
            border:     1px solid #ccc;
            padding:    1px;
            background: #fff;
        }
    }

    .fs-terms
    {
        text-align: center;
        font-size:  0.85em;
        padding:    5px;
        background: rgba(0, 0, 0, 0.05);

        &, a
        {
            color: #999;
        }

        a
        {
            text-decoration: none;
        }
    }
}

@import "multisite-options";
@import "tooltip";
@import "gdpr-consent";

.rtl
{
    #fs_connect
    {
        .fs-actions
        {
            padding:    10px 20px;
            background: #C0C7CA;

            .button
            {
                .dashicons
                {
                    font-size:    37px;
                    margin-left:  -8px;
                    margin-right: 12px;
                }

                &.button-primary
                {
                    &:after
                    {
                        content: ' \000bb';
                    }

                    &.fs-loading
                    {
                        &:after
                        {
                            content: '';
                        }
                    }
                }

                &.button-secondary
                {
                    float: left;
                }
            }
        }

        .fs-permissions
        {
            ul
            {
                li
                {
                    div
                    {
                        margin-right: 55px;
                        margin-left:  0;
                    }

                    i.dashicons
                    {
                        float: right;
                    }

                }
            }
        }

        .fs-visual
        {
            .fs-site-icon
            {
                right: 20px;
                left:  auto;
            }

            .fs-connect-logo
            {
                right: auto;
                left:  20px;
            }
        }
    }
}

#fs_theme_connect_wrapper {
    position: fixed;
    top: 0;
    height: 100%;
    width: 100%;
    z-index: 99990;
    background: rgba(0, 0, 0, 0.75);
    text-align: center;
    overflow-y: auto;

    &:before {
        content: "";
        display: inline-block;
        vertical-align: middle;
        height: 100%;
    }

    > button.close {
        color: white;
        cursor: pointer;
        height: 40px;
        width: 40px;
        position: absolute;
        right: 0;
        border: 0;
        background-color: transparent;
        top: 32px;
    }

    #fs_connect {
        top: 0;
        text-align: left;
        display: inline-block;
        vertical-align: middle;
        margin-top: 52px;
        margin-bottom: 20px;

        .fs-terms
        {
            background: rgba(140, 140, 140, 0.64);

            &, a
            {
                color: #c5c5c5;
            }
        }
    }
}

.wp-pointer-content
{
    #fs_connect
    {
        margin: 0;
        @include box-shadow(none);
    }
}

.fs-opt-in-pointer
{
    .wp-pointer-content
    {
        padding: 0;
    }

    &.wp-pointer-top
    {
        .wp-pointer-arrow
        {
            border-bottom-color: #dfdfdf;
        }
        .wp-pointer-arrow-inner
        {
            border-bottom-color: #fafafa;
        }
    }

    &.wp-pointer-bottom
    {
        .wp-pointer-arrow
        {
            border-top-color: #dfdfdf;
        }
        .wp-pointer-arrow-inner
        {
            border-top-color: #fafafa;
        }
    }

    &.wp-pointer-left
    {
        .wp-pointer-arrow
        {
            border-right-color: #dfdfdf;
        }
        .wp-pointer-arrow-inner
        {
            border-right-color: #fafafa;
        }
    }

    &.wp-pointer-right
    {
        .wp-pointer-arrow
        {
            border-left-color: #dfdfdf;
        }
        .wp-pointer-arrow-inner
        {
            border-left-color: #fafafa;
        }
    }
}
