@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800&display=swap');

:root {
    --white: #fff;
    --black: #373e50; 
    --lightBulue: #17a;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    position: relative;
    margin: 0;
    overflow: hidden;
}

body::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("./images/bg1.jpg");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: -1; /* Ensure it stays behind the content */
}


.wrapper {
    position: relative;
    width: 1000px;
    height: 650px;
    background: var(--white);
    border: 2px solid var(--black);
    border-radius: 10px;
    box-shadow: 0 0 20px var(--black);
    overflow: hidden;
}

.wrapper .form-box {
    position: absolute;
    top: 5%;
    width: 50%;
    height: 100%;
    display: table;
    justify-content: center;
    flex-direction: column;
}

.wrapper .form-box.register {
    padding: 0 40px 0 60px;
    right: 0;
}

.form-box h2 {
    margin-bottom: 10px;
    position: relative;
    font-size: 32px;
    color: var(--black);
    text-align: center;
}

.form-box h2::after {
    content: "";
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 4px;
    background: var(--black);
}

.form-box .input-box {
    position: relative;
    width: 100%;
    height: 50px;
    margin: 25px 0;
}

.input-box input {
    width: 100%;
    height: 100%;
    background: transparent;
    color: var(--black);
    font-size: 16px;
    font-weight: 500;
    border: none;
    outline: none;
    border-bottom: 2px solid var(--black);
    transition: none; /* Removed transition */
    padding-right: 23px;
}

.input-box input:focus,
.input-box input:valid {
    border-bottom-color: var(--lightBulue);
}

.input-box label {
    position: absolute;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    font-size: 16px;
    color: var(--black);
    pointer-events: none;
    transition: none; /* Removed transition */
}

.input-box input:focus~label,
.input-box input:valid~label {
    top: -5px;
    color: var(--lightBulue);
}

.input-box i {
    position: absolute;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    font-size: 18px;
    transition: none; /* Removed transition */
}

.input-box input:focus~i,
.input-box input:valid~i {
    color: var(--lightBulue);
}

form button {
    width: 100%;
    height: 45px;
    background-color: var(--black);
    color: var(--white);
    border: none;
    outline: none;
    border-radius: 40px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: .3s;
}

form button:hover {
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.8);
}

form .linkTxt {
    font-size: 14px;
    color: var(--black);
    text-align: center;
    margin: 20px 0 10px;
}

.linkTxt p a {
    color: blue;
    text-decoration: none;
    font-weight: 600;
}

.wrapper .info-text {
    position: absolute;
    top: 0;
    width: 50%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.wrapper .info-text.register {
    left: 0;
    text-align: left;
    padding: 0 150px 60px 40px;
    pointer-events: none; /* Removed pointer events for the text */
}

.wrapper .info-text h2 {
    font-size: 36px;
    color: var(--white);
    line-height: 1.3;
    text-transform: uppercase;
}

.wrapper .info-text p {
    font-size: 16px;
    color: var(--white);
}

.wrapper .rotate-bg {
    position: absolute;
    left:  0;
    width: 800px;
    height: 750px;
    background: #373e50;
    transform: rotate(0deg) skewY(-50deg);
    transform-origin: top left;
    transition: none; /* Removed transition */
}

/* Additional styling to position logo and title side by side */
.logo-title-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 15px;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 70px;
    margin-left: 55px;
    margin-top: 0%;
}

.title {
    font-size: 24px;
    color: #333;
}

/* Hide the second form section initially */
.form-section {
    display: none;
}

/* Show the form section that is currently active */
.form-section.active {
    display: block;
}

.button-container {
    display: flex;
    justify-content: space-between;
}

/* Custom styles for alternate phone field */
#alt-phone {
    border-color: pink;
}

#alt-phone:focus {
    border-color: blue;
}

/* Adjusting the form-box height and making the form content scrollable */
.form-box {
    max-height: 80vh;
    overflow-y: auto;
}

/* Reducing the gap between fields */
.input-box {
    margin-bottom: 10px;
}

.input-gender {
    margin-bottom: 20px;
    font-size: 18px;
    margin-top: 30px;
}

.input-gender label {
    margin-left: 10px;
}

.input-gender input[type="radio"] {
    margin-left: 60px;
}

.input-gender input[type="radio"]:first-child {
    margin-left: 0; /* Remove margin for the first radio button */
}

/* Two-column layout for some fields */
.two-column {
    display: flex;
    gap: 15px;
}

.two-column .input-box {
    flex: 1;
}

.popup {
    display: none;
    position: fixed;
    top: 20px;
    right: 20px;
    background-color: #373e50; /* Background color */
    color: white; /* Text color */
    padding: 15px;
    border-radius: 5px;
    z-index: 1000;
    transition: opacity 0.5s ease;
}
.popup.show {
    display: block;
    opacity: 1;
}

@media (max-width: 768px) {
    /* Hide the info-text and rotate-bg on mobile */
    .info-text {
        width: 0;
        display: none; /* Hide info text on mobile */
    }
    .info-text .animation{
        display: none;
    }
    .rotate-bg {
        display: none; /* Remove the rotate background */
    }
    .form-box.register {
        width: 100%; /* Adjust the width of the form box */
        margin: 0 auto; /* Center the form box */
    }
    .wrapper .info-text{
        position: absolute;
        top: 0;
        width: 0;
        height: 0;
        display: none;
        flex-direction: column;
        justify-content: center;
    }
    .input-gender input[type="radio"] {
        margin-left: 20px;
    }
    .logo img {
        height: 79px;
        margin-left: 10px;
        margin-top: 0%;
    }
    .wrapper .form-box.register {
        padding: 20px;
        right: inherit;
    }
    
}
