@import 'font';
@import 'mixin';
@import 'button';
@import 'general';

body {
    font-family: 'avenir';
    margin: 0;
}

.alert-error {
    text-align: left;
    color: #a94442;
    font-size: 1rem;
}

#main {
    overflow: hidden;

    .main-container {
        // Default MY Banner
        background-image: url(../images/banner/my/v1/my-banner.jpg);
        background-repeat: no-repeat;
        padding-bottom: 2rem;
        object-fit: cover;
        left: 0;
        top: 0;
        right: 0;
        bottom: 0;
        z-index: 0;
        display: block;
        position: relative;

        background-position: initial;
        background-size: cover;
        background-repeat: no-repeat;
        min-height: 100vh;
        display: flex;
        flex-direction: column;

        .main-grid {
            display: grid;
            grid-template-columns: 40% 60%;
            padding: 8% 0 0;
            gap: 1.5rem;
            position: relative;
            z-index: 10;

            .main-grid-left {
                position: relative;

                .main-header {
                    color: #FFF;
                    font-size: 48px;
                    font-weight: 400;
                    margin-bottom: 1rem;

                    .mobile-container {
                        display: none;
                    }
                }
            }

            .main-grid-right {
                position: relative;
                color: white;

                .info-wrapper {
                    position: absolute;
                    bottom: 0;
                    z-index: 10;

                    .info-header {
                        margin-bottom: 1rem;
                    }

                    h4 {
                        font-size: 2rem;
                        font-weight: bold;
                        margin-bottom: 0;
                    }

                    .info-container {
                        left: initial;
                        display: grid;
                        grid-template-columns: 1fr 2fr 1fr 1fr;
                        margin-top: 0;
                        justify-content: space-evenly;
                        z-index: 2;
                        gap: 0.5rem;

                        .info-item {
                            h4 {
                                text-align: left;
                                padding-left: 0.3rem;
                                white-space: nowrap;
                                font-size: 12px;
                                color: #fff;
                                font-weight: normal;
                                margin-bottom: 0.5rem;
                            }

                            .partner-logo {
                                text-align: center;
                                width: 60%;

                                p {
                                    font-size: 0.75rem;
                                }
                            }

                            .payment-container {
                                display: flex;
                                flex-direction: column;
                                row-gap: 0.5rem;
                                padding-top: 5px;

                                .payment-item {
                                    img {
                                        height: 1.25rem;
                                    }
                                }
                            }

                            &.live-chat {
                                display: flex;
                                align-items: baseline;
                                flex-direction: column;

                                img {
                                    width: 85%;
                                    // margin-top: 0.2rem;
                                }
                            }

                            .lang-box {
                                min-width: 10rem;
                                margin-top: 0.7rem;
                                position: relative;

                                .lang-container-btn {
                                    display: flex;
                                    border-radius: 2rem;
                                    background-color: white;
                                    color: #8697A2;
                                    flex-direction: row;
                                    justify-content: space-between;
                                    padding: 0.3rem;
                                    align-items: center;
                                    cursor: pointer;
                                    user-select: none;

                                    p {
                                        margin: 0;
                                        font-size: 0.75rem;
                                    }

                                    .flag {
                                        width: 1.7rem;
                                        border-radius: 50%;
                                    }
                                }

                                .lang-dropdown-content {
                                    position: absolute;
                                    z-index: 10;
                                    bottom: 2.4rem;
                                    background-color: white;
                                    border-radius: 0.5rem;
                                    padding: 1rem;
                                    color: #8697a2;
                                    width: 13.5rem;
                                    right: 0;
                                    display: none;

                                    &.active {
                                        display: block;
                                    }

                                    .lang-flag-wrapper {
                                        .lang-flag-container {
                                            display: flex;
                                            gap: 0.5rem;
                                            align-items: center;

                                            img {
                                                width: 1.5rem;
                                                height: 1.5rem;
                                                border-radius: 50%;
                                            }

                                            .lang-info {
                                                .country-name {
                                                    margin-bottom: 0;
                                                    font-size: 0.9rem;
                                                    padding-left: 0.5rem;
                                                }

                                                .lang-selection {
                                                    a {
                                                        text-decoration: none;
                                                        color: #8697a2;
                                                        font-size: 0.8rem;
                                                        border-right: 0.01rem solid #ccc;
                                                        padding: 0 0.5rem;
                                                        cursor: pointer;

                                                        &:last-child {
                                                            border: none;
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}

.main-gradient {
    background: linear-gradient(0deg, #a1a0a0 0%, rgba(12, 10, 13, 0) 95.75%);
    mix-blend-mode: multiply;
    width: 100%;
    height: 40rem;
    position: absolute;
    bottom: 0%;
    pointer-events: none;
    filter: blur(10px);
}

#section-form {
    .form-container {
        display: block;
        width: 100%;
        position: relative;
        background-color: #fff;
        border-radius: 10px;
        box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5);
        background-clip: padding-box;
        outline: 0;
        text-align: center;
        padding: 30px;
        -webkit-box-sizing: border-box;
        -moz-box-sizing: border-box;
        box-sizing: border-box;
        margin: 0;

        .tab-header {
            display: flex;
            justify-content: space-between;
            overflow: hidden;
            position: relative;
            align-items: center;

            .tab-header-btn {
                width: 45%;
                font-size: 20px;
                font-weight: bold;
                color: #8a1538;
                margin-bottom: 15px;

                a {
                    padding: 0.5em 0;
                    text-align: center;
                    font-weight: 400;
                    display: block;
                    font-size: 18px;
                    text-decoration: none;
                    background-color: #f3f5f6;
                    border-radius: 25px;
                    color: #0f161f;

                    &.active {
                        background-color: #ff8a00;
                        border-radius: 25px;
                        color: #fff;
                    }
                }
            }
        }

        .tab-content {
            .content-form {
                display: none;

                &.active {
                    display: block;
                }
            }

            .label-text {
                display: block;
                color: #8697a2;
                text-align: left;
                margin-top: 20px;

                &.required {
                    &:after {
                        color: #e0082d;
                        content: "*";
                        margin-left: 0.3rem;
                        font-size: 1rem;
                    }
                }
            }

            .space-50 {
                margin-bottom: 100px;
            }

            .break-line {
                margin: 5% 0;
                border-top: 1px solid #dbe0e4;
            }

            .help-container {
                &.margin {
                    margin-top: 1.5rem;
                }

                h6 {
                    font-size: 12px;
                    color: #8697a2;
                    margin: 0;

                    span {
                        color: #ff8a00;
                        padding: 0;
                    }
                }

                a {
                    color: #ff8a00;
                    text-decoration: none;
                    background-color: rgba(0, 0, 0, 0);
                    outline: none;
                    cursor: pointer;
                    -webkit-transition: color .3s;
                    transition: color .3s;
                }
            }

            .phone-no-dropdown {
                position: relative;
                display: inline-block;
                width: 8rem;

                &.open {
                    .phone-no-dropdown-content {
                        display: block;
                    }
                }

                .phone-no-dropdown-header {
                    border: 1px solid #ced4da;
                    cursor: pointer;
                    padding: 6px;
                    border-radius: 0.5rem;
                    background-color: white;
                    display: flex;
                    align-items: center;
                    color: black;
                    padding-left: 0.7rem;
                    // box-shadow: rgba(0, 0, 0, 0.1) 0px 4px 6px -1px, rgba(0, 0, 0, 0.06) 0px 2px 4px -1px;
                    gap: 0.5rem;

                    .dropdown-arrow {
                        margin-left: auto;
                    }

                    &.alert {
                        border: 2px solid #E84730;
                    }

                    img {
                        width: 24px;
                        border-radius: 50%;
                    }
                }
            }

            .phone-no-dropdown-content {
                display: none;
                position: absolute;
                border: 1px solid #ced4da;
                // background-color: #0F1A30;
                background-color: white;
                color: black;
                max-width: 10rem;
                box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
                z-index: 20;
                width: 100%;
                border-radius: 0.25rem;

                .phone-no-dropdown-item {
                    padding: 10px;
                    display: flex;
                    align-items: center;
                    cursor: pointer;
                    padding-left: 1rem;
                    font-size: 1rem;

                    &:hover {
                        background-color: #ecf0f1;
                        color: black;
                    }

                    img {
                        width: 1.5rem;
                        height: 1.5rem;
                        margin-right: 0.5rem;
                        border-radius: 50%;
                    }
                }
            }

            .phone-no-container {
                display: flex;
                gap: 0.5rem;
            }
        }
    }
}

@media screen and (min-width: 1401px) {
    #main {
        .main-container {
            background-position: initial;
            background-size: cover;
            background-repeat: no-repeat;
            min-height: 100vh;
            display: flex;
            flex-direction: column;
        }
    }
}

@media screen and (min-width: 1280px) and (max-width: 1400px) {
    #main {
        .main-container {
            // background-position: left -14.37rem top;
        }
    }
}

@media screen and (min-width: 992px) and (max-width: 1279px) {
    #main {
        .main-container {
            // background-position: left -14.37rem top;
        }
    }
}

@media screen and (min-width: 768px) and (max-width: 991px) {
    #main {
        .main-container {
            background-image: url(../images/banner/my/v1/my-banner-tablet.jpg);
            // background-position: left -13.37rem top;

            .main-grid {
                .main-grid-right {
                    .info-wrapper {
                        .info-container {
                            grid-template-columns: 0.5fr 1fr;

                            .info-item {
                                &.live-chat {
                                    img {
                                        margin-top: 0;
                                    }
                                }

                                .lang-box {
                                    width: 10rem;
                                }
                            }
                        }

                        h4 {
                            font-size: 1.6rem;
                        }
                    }
                }
            }
        }
    }

    #section-form {
        .form-container {
            .tab-content {
                .phone-no-dropdown {
                    .phone-no-dropdown-header {
                        gap: 0;
                    }
                }
            }
        }
    }
}

@media screen and (max-width: 767px) {
    .container {
        max-width: initial;
        padding: 0;
    }

    body {
        background-color: #0088FF;
    }

    .main-gradient {
        display: none;
    }

    #main {
        .main-container {
            background-image: initial;

            .main-grid {
                padding-top: 0%;
                display: flex;
                flex-direction: column;

                .main-grid-left {
                    .main-header {
                        position: relative;

                        .logo {
                            position: absolute;
                            top: 10%;
                            left: 50%;
                            transform: translate(-50%, -50%);

                            img {
                                width: 8rem;
                            }
                        }

                        .mobile-container {
                            display: block;

                            img {
                                width: 100%;
                            }

                            .info-header {
                                position: absolute;
                                bottom: 3%;
                                left: 0;
                                right: 0;
                                margin-left: auto;
                                margin-right: auto;
                                width: 80%;
                                text-align: center;

                                h4 {
                                    font-family: avenir;
                                    font-weight: bold;

                                    &:nth-child(2) {
                                        width: 70%;
                                        margin-left: auto;
                                        margin-right: auto;
                                    }
                                }
                            }
                        }
                    }
                }

                .main-grid-right {
                    .info-wrapper {
                        position: initial;

                        .info-header {
                            display: none;
                        }

                        .info-container {
                            grid-template-columns: initial;
                            gap: 2rem;

                            .info-item {
                                &:nth-child(3) {
                                    order: 1;

                                    img {
                                        width: 8rem;
                                    }
                                }

                                &:nth-child(4) {
                                    order: 2;
                                }

                                &:nth-child(1) {
                                    order: 3;
                                }

                                &:nth-child(2) {
                                    order: 4;
                                }

                                h4 {
                                    text-align: center;
                                }

                                .partner-logo {
                                    width: 100%;
                                }

                                .lang-box {
                                    width: 14rem;
                                    margin-left: auto;
                                    margin-right: auto;

                                    .lang-dropdown-content {
                                        width: 100%;

                                        .lang-flag-wrapper {
                                            .lang-flag-container {
                                                gap: 1rem;
                                            }
                                        }
                                    }
                                }

                                .payment-container {
                                    .payment-item {
                                        margin-left: auto;
                                        margin-right: auto;
                                    }
                                }

                                &.live-chat {
                                    justify-content: center;
                                    flex-direction: initial;
                                }
                            }
                        }

                    }
                }
            }
        }
    }

    #section-form {
        max-width: 540px;
        width: 100%;
        padding-right: 15px;
        padding-left: 15px;
        margin-right: auto;
        margin-left: auto;
    }
}

@media screen and (max-width: 538px) {
    #main {
        .main-container {
            .main-grid {
                .main-grid-left {
                    .main-header {
                        .mobile-container {
                            margin-bottom: 2rem;

                            .info-header {
                                width: 100%;
                                bottom: -3%;

                                h4 {
                                    // font-size: 1.3rem;
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}