.container-main{
    margin: 0 auto;
    height: 800px;
    max-width: 1200px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.wrapper {
    margin-top: 150px;
    background: transparent;
    width: 650px;
    height: auto;
    position: relative;
    padding: 30px 40px;
    box-shadow: 0 0 8px var(--green);
    border-radius: 20px;
}

.wrapper h1 {
    text-align: center;
    font-size: 2.5em;
    margin-bottom: 30px;
}

.wrapper .input-box{
    width: 100%;
    height: 60px;
    margin: 50px 0;
    position: relative;
}

.input-box input{
    width: 100%;
    height: 100%;
    background: transparent;
    border: none;
    outline: none;
    border: 2px solid lightgrey;
    border-radius: 40px;
    padding: 20px 50px 20px 20px;
    font-size: 18px;
    box-sizing: border-box;
}

.input-box input::placeholder{
    color: black;
}

.input-box input:focus {
    border-color: var(--green);
    box-shadow: 0 0 1px var(--green);
}

.input-box i {
    position: absolute;
    transform: translateY(-50%);
    right: 25px;
    top: 50%;
    font-size: 20px;
    color: #666;
}

.wrapper .btn {
    width: 100%;
    height: 55px;
    background: var(--green);
    border: none;
    outline: none;
    border-radius: 40px;
    box-shadow: 0 0 10px var(--green);
    cursor: pointer;
    font-size: 18px;
    color: black;
    font-weight: 550;
    margin-top: 20px;
    transition: all 0.3s ease;
}

.wrapper .btn:hover {
    box-shadow: 0 0 15px var(--green);
    filter: brightness(0.91);
}

.wrapper .register-link {
    justify-content: center;
    align-items: center;
    display: flex;
    font-size: 18px;
    text-align: center;
    margin: 25px 0 15px;
    gap: 8px;
}

.register-link p {
    color: black;
    margin: 0;
}

.register-link a {
    color: black;
    text-decoration: none;
    font-weight: 600;
}

.register-link a:hover {
    text-decoration: underline;
}

.wrapper .master-register-link {
    justify-content: center;
    align-items: center;
    display: flex;
    font-size: 18px;
    text-align: center;
    margin: 25px 0 15px;
    gap: 8px;
}

.master-register-link p{
    color: black;
    margin: 0;
}

.master-register-link a {
    color: black;
    text-decoration: none;
    font-weight: 600;
}

.master-register-link a:hover {
    color: var(--green);
    transform: scale(1.02);
    transition: 0.3s ease;
}



.btn.loading {
    position: relative;
    color: transparent;
}

.btn.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin: -10px 0 0 -10px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-right-color: transparent;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.form-message {
    transition: all 0.3s ease;
}


.spacer{
    width: auto;
    height: 170px;
}

@media (max-width: 1024px) {
    .wrapper {
        max-width: 550px;
        padding: 25px 35px;
    }
}

@media (max-width: 768px) {
    .container-main {
        padding: 40px 16px;
    }

    .wrapper {
        max-width: 450px;
        padding: 25px;
        margin-top: 100px;
    }

    .wrapper .input-box{
        margin: 35px 0;
    }

    .wrapper h1 {
        font-size: 2em;
    }
    
    /* Предотвращаем zoom на iOS */
    .input-box input {
        font-size: 16px !important;
    }
}

@media (max-width: 480px) {
    .wrapper {
        max-width: 360px;
        padding: 20px;
        border-radius: 15px;
        margin-top: 85px;
    }

    .wrapper h1 {
        font-size: 1.7em;
    }

    .wrapper .register-link{
        gap: 4px;
    }

    .wrapper .master-register-link{
        gap: 4px;
    }

    .spacer {
        height: 80px;
    }
    
    /* Предотвращаем zoom на iOS */
    .input-box input {
        font-size: 16px !important;
    }
}
/* Fix links alignment */
@media (max-width: 768px) {
    .wrapper .register-link,
    .wrapper .master-register-link {
        flex-direction: row !important;
        flex-wrap: wrap;
        justify-content: center;
        align-items: baseline;
    }
}
