body {
    font-family: 'Roboto', sans-serif;
    margin: 0;
    background-image: url(../imagenes/BackIntro2.jpg);
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
    background-position: center;
    color: white;
    display: block;
    min-height: 100vh;
}

.modal {
    background: rgba(0,0,0,0.5);
    width: 100%;
    height: 100vh;
    text-align: center;
    font-family: sans-serif;
    margin: 0;
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
    position: fixed; /* Asegura que cubra toda la pantalla */
    top: 0;
    left: 0;
    z-index: 40;
}

.logueo {
    width: 97%;
    height: 10vh;
    text-align: right;
    position: absolute;
    top: 0;
    left: 0;
}

/* Configuración original para Escritorio */
.arbol {
    position: absolute;
    width: 30%;
    height: 40%;
    top: -26%;
    left: 35%;
    border-radius: 50%;
    background-image: url(../imagenes/arbol.png);
    background-position: center center;
    background-size: 100%;
    background-repeat: no-repeat;
    background-color: white;
    box-shadow: 0 0 20px #000000;
    
}
.arbol1 {
    position: absolute;
    width: 30%;
    height: 32%;
    top: -26%;
    left: 35%;
    border-radius: 50%;
    background-image: url(../imagenes/arbol.png);
    background-position: center center;
    background-size: 100%;
    background-repeat: no-repeat;
    background-color: white;
    box-shadow: 0 0 20px #000000;
    
}


.contenido {
    position: absolute;
    top: 35%;
    left: 65%;
    margin: auto;
    width: 20%;
    height: 30%;
    color: #F7F2EF;
    background: rgba(136,179,69,0.3);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 2s ease-out forwards;
   
}
.contenido1 {
    position: absolute;
    top: 33%;
    left: 65%;
    margin: auto;
    width: 20%;
    height: 40%;
    color: #F7F2EF;
    background: rgba(136,179,69,0.3);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 2s ease-out forwards;
 
}

a {
    color: white;
    text-decoration: none;
}

#cerrar {
    display: none;
}

#cerrar + label {
    position: fixed;
    color: #fff;
    font-size: 12px;
    z-index: 50;
    background: #EA0E3A;
    height: 25px;
    width: 25px;
    line-height: 25px;
    border-radius: 50%;
    right: 10px;
    top: 10px;
    cursor: pointer;
    text-align: center;
    animation: modal 1s;
    animation-delay: 0s;
    animation-fill-mode: forwards;
    visibility: hidden;
    opacity: 0;
}

/* REGLA DE CIERRE: Oculta el botón y la ventana modal cuando el checkbox está activo */
#cerrar:checked + label, 
#cerrar:checked ~ .modal {
    display: none !important;
}

@keyframes modal {
    100% {
        visibility: visible;
        opacity: 1;
    }
}

input {
    width: 100%;
    display: block;
    background-color: white;
    border: none;
    border-bottom: green medium solid;
    text-align: center;
    outline: none;
    padding: 5px 0;
    font-size: .7rem;
    color: #292C2D;
}

::placeholder {
    color: #0A0909;
    opacity: 1;
    font: 14px/100% Arial, sans-serif;
}

.button {
    display: inline-block;
    color: #0A0A09;
    vertical-align: baseline;
    outline: none;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    font-size: .8rem;
    text-shadow: 0 1px 1px rgba(0,0,0,.3);
    border-radius: .5em;
    box-shadow: 0 1px 2px rgba(0,0,0,.2);
    font-weight: bold;
    letter-spacing: 0.25em;
    word-spacing: 0.25em;
    border: none;
    padding: 5px 15px;
}

.button:hover {
    text-decoration: none;
    color: green;
}

.button:active {
    position: relative;
    top: 1px;
}

.black {
    border: solid 1px #333;
    background: #333;
    background: -webkit-gradient(linear, left top, left bottom, from(#666), to(#000));
    background: -moz-linear-gradient(top,  #666,  #000);
}

select {
    margin-bottom: 10px;
    margin-top: 10px;
    font-family: sans-serif;
    outline: 0;
    color: #F4EFEB;
    background: #9a784f;
    font-size: 12px;
    border: 1px solid #231709;
    padding: 4px;
    border-radius: 9px;
    width: 200px;
}

.styled-table {
    border-collapse: collapse;
    margin: 15px 0;
    font-size: 8pt;
    color: white;
    font-family: sans-serif;
    min-width: 450px;
    box-shadow: 0 0 20px #000000;
    margin-left: auto;
    margin-right: auto;
}

.externo {
    color: white;
    font-size: 8pt;
    font-family: sans-serif;
    text-decoration: none;
    letter-spacing: 0.15em;
    word-spacing: 0.25em;
}
.formulario {
    width: 95%;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* AJUSTES ÚNICAMENTE PARA DISPOSITIVOS MÓVILES */
@media (max-width: 768px) {
    .modal {
        align-items: center;
        justify-content: center;
    }

    .contenido {
        position: relative;
        top: 0;
        left: 0;
        width: 85%;
        height: auto;
        padding: 40px 20px;
        box-sizing: border-box;
    }

    .arbol {
        width: 100px;
        height: 100px;
        top: -50px;
        left: 50%;
        transform: translateX(-50%);
    }

    input {
        font-size: 14px;
        padding: 10px 0;
    }

    .button {
        width: 100%;
        padding: 10px;
    }

    .styled-table {
        min-width: 100%;
        font-size: 7pt;
    }
}