@import "_variables.scss";

body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

.App {
    margin: auto;
    width: 100%;
    max-width: max(90%, 1024px);
}

.header-div {
    background-color: #aaa;
    box-sizing: border-box;
    width: 100%;
    height: auto;
    background-color: $header-bg;
    padding: 0 16px;
    position: sticky;
    top: 0;
    left: 0;
    z-index: 1;
    .container {
        @include flexbox(row, flex-start, center);
        height: 60px;

        .logo {
            height: 100%;
            width: 100px;
            img {
                position: relative;
                height: 150px;
                width: 150px;
                left: 0;
                top: 0;
                transform: translateY(-45px) translateX(-25px);
            }
        }

        nav {
            height: 100%;
            ul {
                @include flexbox(row, center, center);
                list-style: none;

                li.dropdown {
                    @include flexbox(row, center, center);
                    .dropdown-open {
                        display: none;
                    }
                    ul {
                        top:40px;
                    }
                    svg {
                        margin-left: 8px;
                    }

                    &:hover {
                        ul {
                            display: block;
                        }
                        .dropdown-open {
                            display: block;
                        }
                        .dropdown-close {
                            display: none;
                        }
                    }
                }

                li {
                    margin: 0 16px;

                    a {
                        color: $header-text-color;
                        position: relative;

                        &:hover {
                            color: $text-color;
                            font-weight: 600;
                        }
                    }

                    ul {
                        display: none;
                        position: absolute;
                        background-color: $header-bg;
                        padding: 16px;
                        border-radius: 4px;
                        box-shadow: 0 0 8px rgba(0, 0, 0, 0.2);
                        li {
                            margin: 8px 10px;
                        }
                    }
                }
            }
        }
        .login-link-div{
            width: 100%;
            text-align: end;

            .login-link {
                a {
                    margin: 0 16px;
                    color: $header-text-color;
                    &:last-child {
                        border-radius: 12px;
                        border: 2px solid $header-text-color;
                        padding: 8px 16px;
    
                        &:hover {
                            border-color: $text-color;
                            color: $text-color;
                        }
                    }
                    &:hover {
                        color: $text-color;
                        font-weight: 600;
                    }
                }
            }

            .profile-link {
                float: right;
                margin-right: 40px;
                .profile-img-icon {
                    width: 50px;
                    height: 50px;
                    border-radius: 50%;
                    background-color: rgb(58, 77, 198);
                    @include flexbox(row, center, center);

                    .dropdown-close, .dropdown-open {
                        transform: translateX(35px);
                        position: absolute;
                    }
                    .dropdown-open{
                        display: none;
                    }
                    p {
                        color: white;
                        font-size: 18px;
                        font-weight: 600;
                        text-align: center;
                        margin-top: 10px;
                        transform: translateY(4px);
                    }
                    ul {
                        display: none;
                        position: absolute;
                        background-color: $header-bg;
                        padding: 16px;
                        border-radius: 4px;
                        list-style: none;
                        box-shadow: 0 0 8px rgba(0, 0, 0, 0.2);
                        transform: translateY(70px);

                        li {
                            margin: 8px 10px;
                        }

                        li a {
                            color: $header-text-color;
                            &:hover {
                                color: $text-color;
                                font-weight: 600;
                            }
                        }
                    }
                }
                &:hover {
                    .dropdown-close {
                        display: none;
                    }
                    .dropdown-open {
                        display: block;
                    }
                    ul {
                        display: block;
                    }
                }
            }
        }
    }
}


.landiing-page {
    box-sizing: border-box;
    width: 90%;
    margin: auto;
    font-family: 'Montserrat', sans-serif;

    .hero-div {
        @include flexbox(row, space-between, center);
        .hero-details {
            width: 80%;
            margin: 5%;
            h1 {
                font-size: 3rem;
            }
            p {
                font-size: 16px;
                font-weight: 500;
                width: 70%;
                line-height: 22px;
            }
            a > button {
                background-color: black;
                font-weight: 600;
                padding: 10px 20px;
                border-radius: 12px;
                margin-top: 1.5rem;
            }
        }
        .hero-img-div {
            width: 65%;
            margin: 5%;
            overflow: hidden;
            img {
                width: 100%;
                object-fit: cover;
                object-position: center;
            }
        }
    }


    .features-div {
        @include flexbox(column, center, center);
        background-color: #f5f5f5;

        .features-heading {
            text-align: center;
            margin: 5% 0;
            h2 {
                font-size: 3rem;
            }
            p { 
                font-size: 16px;
                font-weight: 500;
                letter-spacing: 1px;
                width: 70%;
                line-height: 22px;
                margin: auto;
            }
        }

        .features-cards {
            @include flexbox(row, space-evenly, center);
            margin: 5% 0;
            .card {
                width: 30%;
                margin: 2%;
                padding: 2%;
                border-radius: 12px;
                box-shadow: 0 0 8px rgba(0, 0, 0, 0.2);
                @include flexbox(row, space-evenly, center);
                .card-img {
                    width: 30%;
                    img {
                        width: 100%;
                        object-fit: cover;
                        object-position: center;
                    }
                }
                .card-details {
                    width: 60%;
                    h3 {
                        font-size: 1.5rem;
                        font-weight: 600;
                    }
                    p {
                        font-size: 16px;
                        font-weight: 500;
                        line-height: 22px;
                    }
                }

                &:hover {
                    background-color: #e6e6e6;
                }
            }
        }
    }

    .register-now {
        @include flexbox(row, space-evenly, center);
        margin: 5% 0;
        margin-top: -20px;
        .register-now-details {
            width: 50%;
            h2 {
                font-size: 2.5rem;
            }
            p {
                font-size: 16px;
                font-weight: 500;
                width: 70%;
                line-height: 22px;
                margin: auto;
            }
            a {
                button {
                    background-color: black;
                    font-weight: 600;
                    padding: 10px 20px;
                    border-radius: 12px;
                    margin-top: 1.5rem;
                }
            }
        }
        .register-now-img {
            width: 40%;
            scale: 1.2;
            img {
                width: 100%;
                object-fit: cover;
                object-position: center;
            }
        }
    }
}


footer {
    @include flexbox(row, space-evenly, center);
    position: absolute;
    left:0;
    width: 100%;
    background-color: black;
    .logo {
        height: 100%;
        width: 100px;
        margin: 10px 0;
        scale: 0.8;
        img {
            position: relative;
            height: 150px;
            width: 150px;
            left: 0;
            top: 0;
            transform: translateY(-45px) translateX(-25px);
            filter: invert(80%);
        }
    }

    div {
        color: rgba(255, 255, 255, 0.62);
        padding-bottom: 5%;
        h6 {
            font-size: 18px;
            font-weight: 500;
            color: white;
            transform: translate(30px, 30px);
        }
        ul {
            list-style: none;
            li {
                font-size: 14px;
                cursor: pointer;
                padding: 6px;
                &:hover {
                    color: white;
                    font-weight: 600;
                }
            }
        }
    }
    p{
        position: absolute;
        width: 80%;
        color: white;
        font-size: 12px;
        font-weight: 400;
        bottom: 0;
        margin: 20px 0;
        border-top: 1px solid rgba(255, 255, 255, 0.384);
        padding: 20px;
    }
}


.login-page {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
    background-color: rgba(0, 0, 0, 0.5);
    width: 100%;
    min-height: 100vh;
    @include flexbox(row, center, center);
    background-color: #f5f5f5;

    .login-img-div {
        width: 50%;
        img {
            position: relative;
            left: -150px;
            width: 100%;
            object-fit: cover;
            object-position: center;
        }
    }

    .login-div {
        @include flexbox(column, center, center);
        text-align: center;
        h3 {
            font-size: 1.2rem;
            font-weight: 600;
            text-align: center;
            margin: 10px 0;
        }
        p {
            font-size: 14px;
            font-weight: 500;
            text-align: center;
            margin: 10px 0;

            &.or-line{
                &::before , &::after {
                    content: "";
                    width: 100px;
                    height: 2px;
                    background-color: rgba(0, 0, 0, 0.301);
                    display: inline-block;
                    margin: 7px;
                    transform: translateY(2px);
                }
            }
        }
        .alert {
            width: 80%;
        }
        .form-div {
            width: 80%;
            margin: 5% 0;
            @include flexbox(column, center, center);
            button {
                width: 100%;
                padding: 10px 20px;
                border-radius: 12px;
                border: 1px solid rgba(0, 0, 0, 0.2);
                margin: 10px auto;
                margin-left: 10px;
                background-color: black;
                color: white;
                font-weight: 600;
                &:focus {
                    outline: none;
                }
            }
        }
        .social-login {
            width: 80%;
            margin: auto;
            @include flexbox(row, space-evenly, center);
            a {
                width: 40%;
                padding: 10px 20px;
                border-radius: 12px;
                border: 1px solid rgba(0, 0, 0, 0.2);
                margin: 10px;
                background-color: white;
                color: black;
                font-weight: 600;
                display: inline-flex;
                cursor: pointer;
                text-align: center;
                img {
                    width: 20px;
                    height: 20px;
                    margin-right: 10px;
                }
                &:focus {
                    outline: none;
                }
            }
        }
    }
}

.register-page {
    min-height: 60vh;
    margin-bottom: 20px;
    @include flexbox(row, space-evenly, start);

    .card {
        @include flexbox(column, space-evenly, start);
        border-radius: 12px;
        box-shadow: 0 0 8px rgba(0, 0, 0, 0.2);
        padding: 2%;
        margin: 10px;
        font-size: 1.1rem;

        p {
            font-size: 0.9rem;
        }
    }

}