﻿/* Reset styles */
*, *::before, *::after {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

/* Global styles */
body, input {
    font-family: "Poppins", sans-serif;
}

body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background: url('../images/fondo_login.jpg') no-repeat center center fixed;
    background-size: cover;
    display: flex;
    justify-content: center;
    align-items: center;
}

main {
    width: 100%;
    min-height: 100vh;
    overflow: hidden;
    padding: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Wrapper styles */
.wrapper {
    width: auto;
    background: none;
    color: #000;
    padding: 30px;
}

    .wrapper h1 {
        font-size: 24px;
        text-align: center;
    }

    .wrapper .input-box {
        margin: 20px 0;
    }

/* Input box styles */
.input-box input {
    width: 100%;
    height: 40px;
    border: 1px solid #000;
    border-radius: 5px;
    padding: 5px;
    font-size: 14px;
}

/* Button styles */
.btn {
    width: 100%;
    height: 40px;
    background: #000;
    border: none;
    color: #fff;
    cursor: pointer;
    font-size: 14px;
}

/* Register link styles */
.register-link {
    font-size: 14px;
    text-align: center;
}

/* Footer styles */
.footer {
    position: static;
    color: #000;
}

/* Box styles */
.box {
    position: relative;
    width: 100%;
    max-width: 1020px;
    height: 640px;
    background-color: #fff;
    border-radius: 3.3rem;
    box-shadow: 0 60px 40px -30px rgba(0, 0, 0, 0.27);
}

.inner-box {
    position: absolute;
    width: calc(100% - 4.1rem);
    height: calc(100% - 4.1rem);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.forms-wrap {
    position: absolute;
    height: 100%;
    width: 45%;
    top: 0;
    left: 0;
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: 1fr;
    transition: 0.8s ease-in-out;
}

form {
    max-width: 260px;
    width: 100%;
    margin: 0 auto;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    grid-column: 1 / 2;
    grid-row: 1 / 2;
    transition: opacity 0.02s 0.4s;
}

    form.sign-up-form {
        opacity: 0;
        pointer-events: none;
    }

/* ================= Logo ================= */
.logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    text-align: center;
}

    .logo img {
        width: 220px;
        max-width: 90%;
        height: auto;
        margin-bottom: 0.5rem;
        object-fit: contain;
        filter: drop-shadow(0 4px 6px rgba(0,0,0,0.2));
    }

    .logo h4 {
        font-size: 1.2rem;
        font-weight: 600;
        letter-spacing: 1px;
        color: #151111;
    }

/* Text */
.heading h2 {
    font-size: 2.1rem;
    font-weight: 600;
    color: #151111;
}

.heading h6 {
    color: #bababa;
    font-weight: 400;
    font-size: 0.75rem;
    display: inline;
}

.toggle {
    color: #151111;
    text-decoration: none;
    font-size: 0.75rem;
    font-weight: 500;
    transition: 0.3s;
}

    .toggle:hover {
        color: #8371fd;
    }

.input-wrap {
    position: relative;
    height: 37px;
    margin-bottom: 2rem;
}

.input-field {
    position: absolute;
    width: 100%;
    height: 100%;
    background: none;
    border: none;
    outline: none;
    border-bottom: 1px solid #bbb;
    padding: 0;
    font-size: 0.95rem;
    color: #151111;
    transition: 0.4s;
}

/* ================= CARRUSEL ================= */

.carousel {
    position: absolute;
    height: 100%;
    width: 55%;
    left: 45%;
    top: 0;
    background-color: transparent !important; /* Fondo transparente */
    border-radius: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 0;
    overflow: hidden;
    transition: 0.8s ease-in-out;
}

.images-wrapper {
    display: grid;
    width: 100%;
    height: 100%;
}

.image {
    width: 100%;
    height: 100%;
    object-fit: cover; /* imagen FULL cover */
    grid-column: 1/2;
    grid-row: 1/2;
    opacity: 0;
    transition: opacity 0.3s, transform 0.5s;
}

/* Animaciones individuales */
.img-1 {
    transform: translate(0, -50px);
}

.img-2 {
    transform: scale(0.4, 0.5);
}

.img-3 {
    transform: scale(0.3) rotate(-20deg);
}

.image.show {
    opacity: 1;
    transform: none;
}

/* Text-slider OFF */
.text-slider {
    display: none;
}

/* Bullets */
.bullets {
    display: flex;
    align-items: center;
    justify-content: center;
}

    .bullets span {
        display: block;
        width: 0.5rem;
        height: 0.5rem;
        background-color: #aaa;
        margin: 0 0.25rem;
        border-radius: 50%;
        cursor: pointer;
        transition: 0.3s;
    }

        .bullets span.active {
            width: 1.1rem;
            background-color: #151111;
            border-radius: 1rem;
        }

/* ================= RESPONSIVE ================= */

@media (max-width: 850px) {
    .box {
        height: auto;
        min-height: 600px;
        border-radius: 2rem;
    }

    .inner-box {
        position: static;
        width: 100%;
        height: auto;
        transform: none;
        display: flex;
        flex-direction: column;
    }

    .forms-wrap {
        position: static;
        width: 100%;
        height: auto;
        padding: 2rem;
    }

    form {
        max-width: 400px;
        height: auto;
        padding: 1rem 0;
    }

    .carousel {
        position: static;
        width: 100%;
        height: auto;
        min-height: 300px;
        padding: 0;
        border-radius: 0 0 2rem 2rem;
    }

    .images-wrapper {
        max-height: 280px;
    }

    .image {
        object-fit: contain; /* No se corta en móviles */
        max-height: 280px;
    }
}

@media (max-width: 530px) {
    .carousel {
        min-height: 250px;
    }

    .images-wrapper {
        max-height: 220px;
    }

    .image {
        max-height: 220px;
    }
}

@media (max-width: 380px) {
    .carousel {
        min-height: 200px;
    }

    .images-wrapper {
        max-height: 180px;
    }

    .image {
        max-height: 180px;
    }
}

@media (min-width: 1400px) {
    .box {
        max-width: 1200px;
    }
}
