@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@100;400;700&family=Roboto+Slab:wght@100;400;700&family=Poppins:wght@100;400;700&display=swap");

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Montserrat", sans-serif;
    background-color: #dddddd;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow: hidden;
    padding: 20px;
}

/* Contenedor principal */
.container {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    width: 100%;
    min-height: 100vh;
    overflow: visible;
}

/* Formulario */
.forms-container {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    width: 100%;
    max-width: 600px;
    position: relative;
    z-index: 1;
    padding: 20px;
}

/* Caja del formulario */
.signin-signup {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    background: #fff;
    padding: 40px 30px;
    border-radius: 30px;
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 600px;
    position: relative;
    z-index: 2;
}

/* Círculos decorativos */
.circle {
    position: absolute;
    border-radius: 50%;
    opacity: 0.7;
    z-index: 0;
    transition: all 0.3s ease;
}

/* Círculos específicos */
.circle.top-left {
    width: 60px;
    height: 60px;
    background: #223450;
    top: 58%;
    left: 2%;
}

.circle.bottom-left {
    width: 120px;
    height: 120px;
    background: #82a244;
    bottom: 5%;
    left: 5%;
}

.circle.top-right {
    width: 100px;
    height: 100px;
    background: #a2b3d9;
    top: 4%;
    right: 5%;
}

.circle.bottom-right {
    width: 50px;
    height: 50px;
    background: #223450;
    bottom: 70%;
    right: 2%;
}

/* Texto y campos */
.tittle {
    font-size: clamp(1.5rem, 5vw, 2rem);
    margin-bottom: 1.5rem;
    color: #444;
    font-weight: bold;
    text-align: center;
    width: 100%;
}

.social-text {
    margin-bottom: 20px;
    font-size: clamp(0.875rem, 2.5vw, 1rem);
    color: #666;
    text-align: center;
    width: 100%;
    line-height: 1.6;
}

/* Mensajes de éxito y error */
.success-message {
    background-color: #d4edda;
    color: #155724;
    padding: 12px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    width: 100%;
    text-align: center;
    font-size: 0.9rem;
}

.alert {
    padding: 12px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    width: 100%;
}

.alert-danger {
    background-color: #f8d7da;
    color: #721c24;
}

.alert ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.alert li {
    font-size: 0.9rem;
    margin: 5px 0;
}

.error-text {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: -15px;
    margin-bottom: 10px;
    text-align: left;
    width: 100%;
    max-width: 400px;
    padding-left: 20px;
}

/* Input fields */
.input-field {
    position: relative;
    max-width: 400px;
    width: 100%;
    height: 55px;
    background-color: #f0f0f0;
    margin: 20px auto;
    border-radius: 55px;
    display: grid;
    grid-template-columns: 15% 85%;
    padding: 0 0.4rem;
    border: 2px solid transparent;
    transition: border 0.3s ease-in-out;
}

.input-field i {
    text-align: center;
    line-height: 55px;
    color: #acacac;
    font-size: 1.2rem;
    transition: color 0.3s ease-in-out;
}

.input-field input {
    background: none;
    outline: none;
    border: none;
    font-weight: 600;
    font-size: clamp(0.9rem, 2.5vw, 1.1rem);
    color: #333;
    padding-right: 10px;
}

.input-field input::placeholder {
    color: #acacac;
    font-weight: 500;
}

.input-field:focus-within {
    border-color: #223450;
}

.input-field:focus-within i {
    color: #223450;
}

/* Botones */
.forgot-password-form .btn {
    background-color: #223450;
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: clamp(1rem, 2.5vw, 1.2rem);
    font-weight: bold;
    border-radius: 25px;
    cursor: pointer;
    transition:
        background-color 0.3s ease-in-out,
        transform 0.2s ease;
    margin: 20px auto;
    display: block;
    width: 100%;
    max-width: 300px;
}

.forgot-password-form .btn:hover {
    background-color: #1a2b40;
    transform: scale(1.05);
}

.forgot-password-form .btn:active {
    transform: scale(0.98);
}

.forgot-password-form .btn-secondary {
    background-color: #6c757d;
    margin-top: 10px;
}

.forgot-password-form .btn-secondary:hover {
    background-color: #5a6268;
}

.forgot-password-form .btn i {
    margin-right: 8px;
}

/* Responsive Design */

/* Tablets y dispositivos medianos (768px y menos) */
@media screen and (max-width: 768px) {
    body {
        padding: 15px;
    }

    .signin-signup {
        padding: 35px 25px;
        border-radius: 25px;
    }

    .input-field {
        height: 50px;
        grid-template-columns: 18% 82%;
    }

    .input-field i {
        line-height: 50px;
        font-size: 1.1rem;
    }

    .circle.bottom-left {
        width: 90px;
        height: 90px;
    }

    .circle.top-right {
        width: 80px;
        height: 80px;
    }

    .circle.top-left {
        width: 50px;
        height: 50px;
    }

    .circle.bottom-right {
        width: 40px;
        height: 40px;
    }
}

/* Móviles (480px y menos) */
@media screen and (max-width: 480px) {
    html,
    body {
        margin: 0;
        padding: 0;
        height: 100vh;
    }

    * {
        box-sizing: border-box;
    }

    .forms-container {
        padding: 10px;
    }

    .signin-signup {
        padding: 30px 20px;
        border-radius: 20px;
        box-shadow: 3px 3px 10px rgba(0, 0, 0, 0.1);
    }

    .tittle {
        margin-bottom: 1rem;
    }

    .social-text {
        margin-bottom: 15px;
    }

    .input-field {
        height: 48px;
        margin: 15px auto;
        grid-template-columns: 20% 80%;
    }

    .input-field i {
        line-height: 48px;
        font-size: 1rem;
    }

    .forgot-password-form .btn {
        padding: 12px 25px;
        margin: 15px auto;
    }

    /* Ajustar círculos para móviles */
    .circle.bottom-left {
        width: 70px;
        height: 70px;
        bottom: 3%;
        left: 3%;
    }

    .circle.top-right {
        width: 60px;
        height: 60px;
        top: 3%;
        right: 3%;
    }

    .circle.top-left {
        width: 40px;
        height: 40px;
        top: 60%;
        left: 1%;
    }

    .circle.bottom-right {
        width: 35px;
        height: 35px;
        bottom: 72%;
        right: 1%;
    }

    .error-text {
        font-size: 0.8rem;
        padding-left: 15px;
    }

    .alert {
        padding: 10px 15px;
    }

    .alert li {
        font-size: 0.85rem;
    }

    .success-message {
        padding: 10px 15px;
        font-size: 0.85rem;
    }
}

/* Móviles pequeños (360px y menos) */
@media screen and (max-width: 360px) {
    .signin-signup {
        padding: 25px 15px;
    }

    .input-field {
        height: 45px;
        margin: 12px auto;
    }

    .input-field i {
        line-height: 45px;
        font-size: 0.95rem;
    }

    .forgot-password-form .btn {
        padding: 10px 20px;
        margin: 12px auto;
    }

    /* Círculos más pequeños para pantallas muy pequeñas */
    .circle.bottom-left {
        width: 50px;
        height: 50px;
    }

    .circle.top-right {
        width: 45px;
        height: 45px;
    }

    .circle.top-left {
        width: 30px;
        height: 30px;
    }

    .circle.bottom-right {
        width: 28px;
        height: 28px;
    }
}

/* Pantallas grandes (1200px y más) */
@media screen and (min-width: 1200px) {
    .signin-signup {
        padding: 50px 40px;
    }

    .input-field {
        height: 60px;
    }

    .input-field i {
        line-height: 60px;
        font-size: 1.3rem;
    }
}


    .error-message {
    display: block;
    font-size: 0.82rem;
    margin-top: 3px;

    /* estilo minimalista */
    color: #d9534f;                 /* rojo suave */
    font-weight: 400;
    letter-spacing: 0.3px;

    /* animación delicada */
    opacity: 0;
    transform: translateY(-2px);
    animation: fadeIn 0.25s ease-out forwards;
}

@keyframes fadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
