@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100..900;1,100..900&display=swap');

*{
  padding: 0;
  margin: 0;
  box-sizing: border-box;
  font-family: "Roboto", sans-serif;
  font-style: normal;
}

html, body {
    margin: 0; 
    height: 100%;
}

body {
    display: flex;
    flex-direction: column; 
}

img{
    display: block;
    width: 100%;
    height: auto;
}

main{
    flex: 1;
}

.img_banner{
    width: 100%;
}

.container_form{
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2.5rem 1rem;
}

.form{
    padding: 1rem;
    width: 100%;
    max-width: 500px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: .5rem;
}

.row-form{
    width: 100%;
    padding: .8rem;
    display: grid;
    place-items: center;
    gap: .5rem;
}

.label{
    font-weight: 600;
    font-size: clamp(1rem, 2vw, 1.2rem);
    text-align: center;
}

.input{
    width: 100%;
    padding: .9rem;
    outline: none;
    transition: all .5s ease;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1rem;
}

.input::placeholder{
    text-align: center;
}

.input:focus {
    border: 2px solid #19c3cc;
}

.btn{
    cursor: pointer;
    padding: .67rem 1rem;
    background: #28a745;
    color: white;
    outline: none;
    border: 0;
    border-radius: 5px;
    font-size: 1rem;
    min-width: 150px;
    transition: background-color 0.3s;
}

.btn_exit{
    cursor: pointer;
    padding: .67rem 1rem;
    background: red;
    color: white;
    outline: none;
    border: 0;
    text-decoration: none;
    border-radius: 5px;
    font-size: 1rem;
    min-width: 150px;
    display: inline-block;
    text-align: center;
    transition: background-color 0.3s;
}

.btn:hover{
    background: #11832b;
}

.btn_exit:hover{
    background: #cc0000;
}

footer {
    width: 100%;
    background-color: #09294b;
    padding: 1.5rem;
    margin-top: auto;
}

.row_footer{
    display: grid;
    place-items: center;
    gap: .5rem;
}

.title{
    color: white;
    font-weight: bold;
    letter-spacing: 1.5px;
    font-size: clamp(1rem, 2.5vw, 1.2rem);
}

.subtitle{
    color: white;
    font-weight: 500;
    letter-spacing: 1px;
    font-size: clamp(0.9rem, 2vw, 1rem);
}

.text-error{
    color: red;
    font-weight: 400;
    font-size: 0.9rem;
    text-align: center;
}

.cont{
    display: none;
    display: grid;
    place-items: center;
    padding: 1.4rem 1rem;
    gap: 1rem;
}

.con_preguntas {
    width: 100%;
    max-width: 800px;
    background-color: #ffffff;
    border: 1px solid #ccc;
    border-radius: 5px; 
    padding: 20px;
    margin: 20px 0;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); 
}

.cont_encuesta {
    background-color: #f9f9f9;
    border: 1px solid #ccc;
    border-radius: 5px; 
    padding: 15px; 
    margin: 10px 0;
    display: flex; 
    flex-direction: column;
    gap: 1rem;
    justify-content: center; 
    align-items: center;
}

.cont_encuesta span {
    font-size: clamp(1rem, 2.5vw, 1.125rem); 
    font-weight: bold;
    text-align: center;
}

.cont_encuesta button {
    background-color: #007bff; 
    color: white; 
    border: none; 
    border-radius: 5px; 
    padding: 10px 20px; 
    cursor: pointer; 
    transition: background-color 0.3s;
    font-size: 1rem;
    min-width: 150px;
}

.cont_encuesta button:hover {
    background-color: #0056b3; 
}

.const_container{
    background-color: #f9f9f9;
    border: 1px solid #ccc;
    border-radius: 5px; 
    padding: 15px; 
    margin: 10px 0;
    display: flex; 
    justify-content: center; 
    align-items: center;
}

.btn_down{
    cursor: pointer;
    padding: .67rem 1rem;
    background: #28a745;
    color: white;
    outline: none;
    border: 0;
    border-radius: 5px;
    text-decoration: none;
    font-size: 1rem;
    min-width: 150px;
    display: inline-block;
    text-align: center;
    transition: background-color 0.3s;
}

.btn_down:hover{
    background: #11832b;
}

.active{
    background-color: gray!important;
    cursor: not-allowed;
}

/* Media Queries para Responsividad */

/* Tablets */
@media screen and (max-width: 768px) {
    .container_form{
        padding: 1.5rem 1rem;
    }
    
    .form{
        width: 100%;
        max-width: 600px;
        padding: 1rem 0.5rem;
    }
    
    .con_preguntas {
        width: 95%;
        padding: 15px;
    }
    
    .cont_encuesta {
        padding: 12px;
    }
    
    .btn, .btn_exit, .btn_down, .cont_encuesta button {
        width: 100%;
        max-width: 300px;
    }
}

/* Móviles */
@media screen and (max-width: 480px) {
    .container_form{
        padding: 1rem 0.5rem;
    }
    
    .form{
        padding: 0.5rem;
    }
    
    .row-form{
        padding: 0.5rem;
    }
    
    .label{
        font-size: 1rem;
    }
    
    .input{
        padding: 0.7rem;
        font-size: 0.9rem;
    }
    
    .con_preguntas {
        width: 100%;
        padding: 10px;
        margin: 10px 0;
    }
    
    .cont_encuesta {
        padding: 10px;
        gap: 0.8rem;
    }
    
    .cont_encuesta span {
        font-size: 0.95rem;
    }
    
    .btn, .btn_exit, .btn_down, .cont_encuesta button {
        padding: 0.6rem 0.8rem;
        font-size: 0.9rem;
        width: 100%;
    }
    
    footer{
        padding: 1rem;
    }
    
    .title{
        font-size: 1rem;
    }
}

/* Pantallas muy pequeñas */
@media screen and (max-width: 320px) {
    .label{
        font-size: 0.9rem;
    }
    
    .input{
        padding: 0.6rem;
        font-size: 0.85rem;
    }
    
    .btn, .btn_exit, .btn_down, .cont_encuesta button {
        padding: 0.5rem;
        font-size: 0.85rem;
        min-width: 120px;
    }
}