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

/* Body Styles */
body.login {
    font-family: Arial, sans-serif;
    background-image: url(../../images/referidos.png);
    background-repeat: no-repeat;
    background-size: 100% 100%;
    background-position: center; /* Centra la imagen */
    color: #333;
    position: relative;
    min-height: 100vh;
    padding: 1vh;
}

body.register {
    font-family: Arial, sans-serif;
    background-attachment: fixed;
    background-image: url(../../images/register1.png);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center; /* Centra la imagen */
    color: #333;
    position: relative;
    min-height: 100vh;
    padding: 1vw;
}

body.resetpass {
    font-family: Arial, sans-serif;
    background-attachment: fixed;
    background-image: url(../../images/fondomorado.png);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center; /* Centra la imagen */
    color: #333;
    position: relative;
    min-height: 100vh;
    padding: 1vw;
}

#fondomorado {
    display:none;   
}

#logolado2 {
    position: fixed;
    top: 0;
    left: 30%;
    width: 30%;
    text-align: center;
}


/* Contenedor de información alineado a la derecha */
.refhead {
    position: absolute;
    top: 20%; /* Margen superior */
    left:48%;
    width: 30%; /* Cambia el ancho aquí */
    max-width: 900px; /* Cambia el ancho máximo aquí */
    height: auto; /* Cambia si quieres una altura específica */
    color: white;
    background: transparent;
    font-weight:bold;
    font-size: 3vw;
}

.image-container {
    position: relative;
    margin-bottom: 10px; /* Espacio entre las imágenes, ajusta según necesites */
}

.number {
    position: absolute;
    top: 20px; /* Ajusta según necesites */
    left: 6%;
    transform: translateX(-50%);
    font-size: 45px; /* Ajusta el tamaño de la fuente según necesites */
    color: purple; /* Ajusta el color según necesites */
    background: rgba(0, 0, 0, 0); /* Fondo semitransparente para mejor legibilidad */
    padding: 2px 5px; /* Ajusta el relleno según necesites */
    
}

.text {
    position: absolute;
    top: 25px; /* Ajusta según necesites */
    left: 15%;
    font-size: 20px; /* Ajusta el tamaño de la fuente según necesites */
    color: white; /* Ajusta el color según necesites */
    background: rgba(0, 0, 0, 0); /* Fondo semitransparente para mejor legibilidad */
    width:350px;
}


.image-container img {
    display: block;
    width: 12%; /* Asegura que la imagen ocupe el ancho del contenedor */
    height: auto; /* Mantiene la proporción de la imagen */
}

/* Contenedor de información alineado a la derecha */
.refheadreg {
    position: absolute;
    top: .5%; /* Margen superior */
    width: 100%; /* Cambia el ancho aquí */
    max-width: 1900px; /* Cambia el ancho máximo aquí */
    height: auto; /* Cambia si quieres una altura específica */
    color: white;
    background: transparent;
    font-weight:bold;
    font-size:2vw;
}
#chevron{
    /*position:absolute;
    top:15%;*/
    left:10%;
    width:10%;
    height:auto;
    
}
.recpass {
    position: fixed;
    top:50%;
    left:25%;
    transform: translateX(-50%);
    transform: translateY(-50%);
    width: 50%;
    height: fit-content;
    background-color: rgba(255, 255, 255, 0.9); /* Fondo semitransparente */
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    text-align: center;
}


/* Formulario de inicio de sesión centrado en la parte inferior */
.log {
    position: fixed;
    top:50%;
    right: 7.5%; /* Centrado horizontalmente */
    transform: translateX(-50%);
    transform: translateY(-50%);
    width: 20vw;
    height: fit-content;
    background-color: rgba(255, 255, 255, 0.9); /* Fondo semitransparente */
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    text-align: center;
}
.log .container {
    margin-bottom: 10px; /* Reducimos el espacio entre el formulario y el carrusel */
}
.buttonRefered{
    width: 7vw;
    font-size: 1vw;
    background-color: #382465;
    color: white;
    border: 0;
    border-radius: 10px;
    padding: 10px 15px;
    box-shadow: 0 0 10px black;
}

.buttonRefered:hover{
    background-color: #6d11a1;
    
}
.buttonBox{
    position:relative;
    max-width: fit-content;
    min-width: fit-content;
  }

#fifth{
overflow:hidden;
border: 0px solid rgba(255, 255, 255, 0);
transition:all .2s ease-in-out;
border-radius: 1vw;
}

#fifth:before{
content:" ";
display:block;
width:10vw;
height:4vw;
background:rgba(255, 255, 255, .4);
position:absolute;
top:-1vw;
left:-10vw;
transform:rotate(-45deg);
transition:all .2s ease-in-out;  
}

#fifth:hover:before{
margin-left:300%;
}

#fifth:hover {
border: 0px solid rgba(255, 255, 255, 1);
}
/* Carousel Container */
.carousel {
    position: relative;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    margin-top: 5px;
}

/* Carousel Items */
.carousel-item {
    position: relative;
    width: 100%;
    display: grid;
    place-items: center;
}

/* Carousel Images */
.carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    max-height: 80vh;
}



/* Text Overlays */
.diagonal-text301a,
.diagonal-text301b,
.diagonal-text303a,
.diagonal-text303b,
.diagonal-text305 {
    font-size:1.1vw;
    color: white;
}

.target{
    position: absolute;
    top: 30%; /* Espacio desde la parte inferior */
    left: 57%; /* Centrado horizontalmente */
    transform: translateX(-50%);
    width: 500px;
    background-color: transparent; /* Fondo semitransparente */
    padding: 5px;
    border-radius: 10px;
    text-align: center;
}


.diagonal-text301a {
    position: absolute;
    top: 21%;
    left: 42%;
    line-height: 1;
    transform: translate(-50%, -50%) rotate(-15deg); /* Rota el texto x grados */
    color: white; /* Color del texto */
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.7); /* Sombra para mejor legibilidad */
    z-index: 1; /* Asegura que el texto aparezca sobre la imagen */
}
.diagonal-text301b {
    position: absolute;
    top: 45%;
    left: 48%;
    transform: translate(-50%, -50%) rotate(-14deg); /* Rota el texto x grados */
    color: white; /* Color del texto */
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.7); /* Sombra para mejor legibilidad */
    z-index: 1; /* Asegura que el texto aparezca sobre la imagen */
}
.diagonal-text303a {
    position: absolute;
    top: 28%;
    left: 45%;
    width:50%;
    line-height: 1;
    transform: translate(-50%, -50%) rotate(-0deg); /* Rota el texto x grados */
    color: white; /* Color del texto */
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.7); /* Sombra para mejor legibilidad */
    z-index: 1; /* Asegura que el texto aparezca sobre la imagen */
}
.diagonal-text303b {
    position: absolute;
    top: 50%;
    left: 50%;
    line-height: 1;
    transform: translate(-50%, -50%) rotate(-19deg); /* Rota el texto x grados */
    color: white; /* Color del texto */
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.7); /* Sombra para mejor legibilidad */
    z-index: 1; /* Asegura que el texto aparezca sobre la imagen */
}
.diagonal-text305 {
    position: absolute;
    top: 50%;
    left: 53%;
    width: 50%;
    transform: translate(-50%, -50%) rotate(-0deg); /* Rota el texto x grados */
    color: white; /* Color del texto */
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.7); /* Sombra para mejor legibilidad */
    z-index: 1; /* Asegura que el texto aparezca sobre la imagen */
}

/* Títulos */
.log h1 {
    font-size: 2vw;
    color: #333;
}

/* Grupos de formularios */
.form-group {
    margin-bottom: .5vw;
}

label {
    display: block;
    margin-bottom: .1vw;
    font-weight: bold;
    color: #333;
}

input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    outline: none;
    transition: border-color 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
}

input:focus {
    border-color: #007bff;
    box-shadow: 0 0 5px rgba(0, 123, 255, 0.5);
}

/* Botón de envío */
button {
    width: 100%;
    padding: 10px;
    background-color: #7F00FF;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s ease-in-out, transform 0.2s ease-in-out;
}

button:hover {
    background-color: #5e00d1;
}

button:active {
    transform: translateY(0);
}

/* Enlaces */
.links {
    margin-top: .5vw;
}

.links a {
    color: #7F00FF;
    text-decoration: none;
    margin: 0 5px;
    transition: color 0.3s;
}

.links a:hover {
    text-decoration: underline;
}

/* Estilos para el checkbox y su contenedor */
.checkbox-group {
    display: flex;
    align-items: center;
    margin: 15px 0;
    gap: 10px;
}

.checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.checkbox-group label {
    color: #9c27b0;
    font-size: 14px;
}

.checkbox-group a {
    color: #9c27b0;
    text-decoration: none;
}

.checkbox-group a:hover {
    text-decoration: underline;
}

/* Estilo para mensaje de error */
.error-message {
    color: #ff4444;
    font-size: 14px;
    margin-top: 5px;
    display: none;
}

                    /*Seccion de Terminos y Condiciones*/
.terms-section {
    padding-top: 3%;
    
    
}

.terms-content {
    max-width: 50vw;
    max-height: 50vh;
    margin-top:12%;
    margin-left: 0%; /* Esto moverá el contenedor a la derecha */
    margin-right: auto; /* Espacio desde el borde derecho */
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 20px;
    overflow: auto;
    
}

.terms-header {
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 5px;
    border-bottom: 2px solid #9c27b0;
}

.terms-header h1 {
    color: #9c27b0;
    font-size: 2.5em;
    margin-bottom: 5px;
}

.update-date {
    color: #666;
    font-style: italic;
}

.terms-body {
    color: #333;
    
}

.term-item {
    margin-bottom: 20px;
}

.term-item h2 {
    color: #9c27b0;
    font-size: 1.5em;
    margin-bottom: 10px;
}

.term-item p {
    line-height: 1.6;
    margin-bottom: 10px;
    margin-left:2%;
}

.term-item ul {
    padding-left: 20px;
    margin-bottom: 15px;
    margin-left:3%;
}

.term-item li {
    margin-bottom: 10px;
    line-height: 1.6;
}



/* Versión oscura para el fondo morado */
.dark-theme {
    background-color: #9c27b0;
    color: white;
}

.dark-theme .terms-content {
    background-color: rgba(0,0,0,0.2);
    color: white;
}

.dark-theme .terms-header h1,
.dark-theme .term-item h2 {
    color: white;
}

.dark-theme .update-date {
    color: rgba(255,255,255,0.8);
}

.dark-theme .terms-header {
    border-bottom-color: rgba(255,255,255,0.2);
}
/* Responsividad General */
@media (max-width: 1024px) {
    .refhead {
        left: 5%;
        width: 90%;
        font-size: 45px;
        text-align: center;
    }
    
    .refheadreg{
        font-size: 2vh;
    }
    
    .terms-section{
        padding-top: 5vh;
    }
    
    .terms-content{
        max-width: 100%;
        max-height: 40vh;
    }

    .log {
        position: relative;
        top: auto;
        right: auto;
        transform: none;
        width: 90%;
        margin: 20px auto;
    }

    #rompecabezas {
        width: 50%;
        left: 25%;
    }

    #gana {
        width: 30%;
        left: 35%;
    }
}

@media (max-width: 768px) {
    body.login {
        background-image: url(../../images/referidosm.png);
        background-size: 90% auto; /* Ajusta el ancho al 100% y altura automática */
        background-position: top center;
        padding-bottom: 70vh; /* Añadimos padding inferior para que el contenido no quede detrás del formulario */
        overflow: hidden;
    }
    .container {
        min-height: 80vh;
        height: auto;
        position: block;
    }
    
    .refhead {
        left: 10%;
        top: 17%;
        font-size:40px;
        width: 30%; /* Casi todo el ancho en tablets más pequeñas */
        max-width: none;
    }
    
    .refheadreg{
        font-size: 2vh;
    }
    
    .terms-section{
        padding-top: 5vh;
    }
    
    .terms-content{
        max-width: 100%;
        max-height: 40vh;
    }

    .log {
        position: fixed; /* Cambiamos a fixed para que se mantenga en la parte inferior */
        bottom: 0; /* Lo posicionamos en la parte inferior */
        top: auto; /* Removemos el top */
        right: 0; /* Lo alineamos a la derecha */
        left: 0; /* Lo alineamos a la izquierda */
        transform: none; /* Removemos la transformación */
        width: 100%; /* Ocupará todo el ancho */
        margin: 0; /* Quitamos márgenes */
        border-radius: 10px 10px 0 0; /* Redondeamos solo las esquinas superiores */
        max-height: 45vh; /* Altura máxima del 80% de la ventana */
        overflow-y: auto; /* Permite scroll si el contenido es muy largo */
        
    }
    
    .carousel {
        margin-bottom: 0;
        
    }

    .carousel-item img {
        height: 70vh; /* Reducimos un poco la altura en tablets */
    }

    .buttonRefered {
        width: 100%;
        font-size: 14px;
    }
    
    .diagonal-text301a,
    .diagonal-text301b,
    .diagonal-text303a,
    .diagonal-text303b,
    .diagonal-text305 {
        font-size: 30px;
    }
    .terms-content {
        padding: 20px;
        margin: 15px;
    }

    .terms-header h1 {
        font-size: 1.8em;
    }

    .term-item h2 {
        font-size: 1.3em;
    }
    
    /* Asegurarse de que el formulario no tape la imagen */
    .log {
        margin-top: 250px; /* Ajusta este valor según sea necesario */
    }
}



@media (max-width: 480px) {
    body.login {
        background-image: url(../../images/referidosm.png);
        background-size: 100% auto; /* Ajusta el ancho al 100% y altura automática */
        background-position: top center;
        padding-bottom: 100vh; /* Aumentamos el padding inferior para dar más espacio */
        overflow-x: hidden;
        position: relative;
        min-height: 100vh;
    }
    .container {
        display: flex;
        flex-direction: column;
        min-height: 100vh;
        position: relative;
    }
    
   #logolado2 {
        position: fixed;
        top: 10%;
        left: 0%;
        width: 100%;
        text-align: center;
    }
    
   .recpass {
        position: fixed;
        top:50%;
        left:2%;
        transform: translateX(-50%);
        transform: translateY(-50%);
        width: 95%;
        height: fit-content;
        background-color: rgba(255, 255, 255, 0.9); /* Fondo semitransparente */
        padding: 20px;
        border-radius: 10px;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
        text-align: center;
    }
    
    /* Contenedor de información alineado a la derecha */
    .refhead {
        position: relative;
        margin-top: 22%;
        left: 0;
        width: 80%;
        padding: 20px;
        z-index: 2;
        margin-bottom: 10vh; /* Espacio para el formulario */
    }
    
    .text {
        font-size: 14px;
        top:20%;
        margin-left: 0%;
        width: 100%;
        color: white;
        text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
        background-color:rgba(0, 0, 0, 0.5);
    }

    .number {
        font-size: 20px;
        top:10px;
        left: 5%;
    }

    .image-container {
        margin-bottom: 10px;
        position: relative;
        display: flex;
        opacity: .7;
    }
    
    .image-container img {
        width: 11%;
        height: auto;
        margin-right: 10px;
    }

    
    .terms-section{
        padding-top: 5vh;
    }
    
    .terms-content{
        max-width: 100%;
        max-height: 40vh;
    }

    .log {
        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        /* Reducimos la altura máxima */
        max-height: 45vh;
        background-color: rgba(255, 255, 255, 0.95);
        border-radius: 20px 20px 0 0;
        padding: 15px;
        z-index: 1000;
        box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.2);
        overflow-y: auto;
        transform: translateY(0);
        transition: transform 0.3s ease-in-out;
    }
    .log .container {
        padding: 10px;
        margin-bottom: 20px;
    }

    .log h1 {
        font-size: 20px;
        margin-bottom: 15px;
    }

    .form-group {
        margin-bottom: 12px;
    }
    .log-hidden {
        transform: translateY(100%);
    }

     /* Ajustamos los inputs y botones para mejor usabilidad en móvil */
    .log input,
    .log button {
        height: 40px; /* Altura mínima para mejor interacción táctil */
        margin-bottom: 10px;
    }

    .log button {
        margin-top: 10px;
    }

    .carousel {
        margin-top: 10px;
        max-height: 30vh;
    }

    .carousel-item img {
        max-height: 45vh;
        width: auto;
    }
    
    .diagonal-text301a,
    .diagonal-text301b,
    .diagonal-text303a,
    .diagonal-text303b,
    .diagonal-text305 {
        font-size: 25px;
    }
    .candado {
        top: 25%;
    }

    .candado img {
        width: 120px; /* Aún más pequeño para pantallas muy pequeñas */
    }
    
}

/* Ajustes para pantallas muy pequeñas */
@media (max-width: 360px) {
    .refhead {
        font-size: 24px;
    }
    
    .refheadreg{
        font-size: 2vh;
    }
    
    .terms-section{
        padding-top: 5vh;
    }
    
    .terms-content{
        max-width: 100%;
        max-height: 40vh;
    }

    .log {
        padding: 10px;
    }

    .buttonRefered {
        padding: 8px 12px;
        font-size: 12px;
    }
}