/* Importar la fuente Montserrat */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&display=swap');

/* Estilos generales */
body {
    font-family: 'Montserrat', sans-serif;
    background-image: url('FONDO3.jpg');
    background-size: cover;
    background-position: center;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
}

/* Contenedor principal */
.container {
    width: 80%;
    max-width: 500px;
    height: auto;
    padding: 15px;
    background-color: white;
    border-radius: 40px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: relative;
}

/* Lista de candidatos */
#listaCandidatos {
    width: 100%;
    padding: 8px;
    border: 2px solid #1E3A6A;
    font-size: 14px;
    font-family: 'Montserrat', sans-serif;
    color: #1E3A6A;
    background-color: white;
    outline: none;
    height: 150px;
    overflow-y: auto;
}

/* Estilo de opciones dentro de la lista */
#listaCandidatos option {
    padding: 8px;
    font-size: 14px;
    border-bottom: 1px solid #1E3A6A;
}

/* Nombre del candidato en negrita y azul oscuro */
#listaCandidatos option:first-line {
    font-weight: bold;
    color: #1E3A6A;
}

/* Partido y elección en azul claro */
#listaCandidatos option span {
    display: block;
    color: #c7daf0;
    font-size: 12px;
}

/* Personalización de la barra de desplazamiento */
#listaCandidatos::-webkit-scrollbar {
    width: 10px;
}

#listaCandidatos::-webkit-scrollbar-track {
    background: #f1f1f1;
}

#listaCandidatos::-webkit-scrollbar-thumb {
    background: #1E3A6A;
    border-radius: 5px;
}

/* Sección de resultado */
#resultadoTexto {
    width: 100%;
    padding: 5px;
    border: 2px solid #1E3A6A;
    font-size: 14px;
    font-family: 'Montserrat', sans-serif;
    color: #1E3A6A;
    background-color: white;
    text-align: center;
    resize: none;
    outline: none;
    border-radius: 5px;
}
/* Encabezado celeste que cubre flecha y texto */
.header {
    width: calc(100% - 1px); /* Ajuste para que quede dentro del cuadro */
    background-color: #c7daf0; /* Azul celeste */
    padding: 20px; /* Espaciado interno reducido */
    border-radius: 40px 40px 0 0; /* Redondeado arriba */
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    font-family: 'Montserrat', sans-serif; /* Fuente Montserrat */
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
}

/* Flecha de regreso dentro del encabezado */
.btn-inicio {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
}

.btn-inicio img {
    width: 50px; /* Reducción de tamaño */
    height: 40px;
}

/* Texto del encabezado con Montserrat */
.header h2 {
    color: #183f6f;
    margin: 0;
    font-size: 1em;
    font-weight: bold;
    text-align: center;
}

/* Búsqueda por voz */
/* Ajustar la posición de la imagen de micrófono */
.buscar-voz {
    text-align: center;
    margin-bottom: 5px; /* Reducido para acercar la búsqueda por texto */
    margin-top: 50px; /* Reducido para acercarlo al encabezado */
}

/* Reducir el espacio entre la imagen del micrófono y el texto "Buscar con voz" */
.buscar-voz img {
    width: 150px; /* Reducido el tamaño si es necesario */
    height: 130px;
    margin-bottom: -45px; /* Acerca el texto "Buscar con voz" */
}

/* Acercar la búsqueda por texto a la imagen del micrófono */
.buscar-candidato {
    margin-top: 5px; /* Reducido el espacio superior */
}


/* Búsqueda por texto */
.buscar-candidato {
    display: flex;
    justify-content: center;
    margin-bottom: 15px;
    position: relative;
    width: 90%;
    max-width: 350px;
    margin-left: auto;
    margin-right: auto;
}

#inputCandidato {
    width: 100%;
    padding: 6px 40px 6px 10px;
    border: 2px solid #1E3A6A;
    border-radius: 25px;
    font-size: 14px;
    outline: none;
}

.btn-buscar {
    background: transparent;
    border: none;
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 25px;
    height: 25px;
    cursor: pointer;
    padding: 0;
}

.btn-buscar img {
    width: 100%;
    height: auto;
}

/* Lista de candidatos */
#listaCandidatos {
    width: 100%;
    padding: 8px;
    border: 2px solid #1E3A6A;
    font-size: 12px;
}

/* Sección Consultar */
.label {
    color: #0d0d0e;
    margin: 8px 0;
    text-align: center;
}

.consultar {
    display: flex;
    justify-content: center;
}

#consultaCandidato {
    width: 50%;
    height: 20px;
    padding: 5px;
    border: 2px solid #1E3A6A;
    border-radius: 10px;
    resize: vertical;
}

.consultar button {
    background: #1E3A6A;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: bold;
}


/* Sección Resultado */
.resultado {
    position: relative;
    width: 280px; /* Más largo */
    height: 45px; /* No muy alto */
    border: 3px solid #1E3A6A; /* Bordes azules */
    padding: 10px;
    border-radius: 0px; /* Bordes ligeramente redondeados */
    background-color: #f8f8f8;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: row; /* Elementos en fila */
    margin: 10px auto; /* Centrado */
}

/* Texto del resultado */
#resultadoTexto {
    width: 80%;
    height: 50px; /* Ajustado al nuevo tamaño */
    padding: 5px;
    resize: none;
    background-color: #fff;
    font-size: 12px; /* Tamaño reducido */
    text-align: center; /* Centrar texto */
    border: none;
    outline: none;
    border-radius: 5px;
}

/* Botón de audio */
.btn-audio {
    position: absolute;
    right: 10px; /* Ubicado al costado derecho */
    border: none;
    border-radius: 50%;
    width: 45px; /* Más grande */
    height: 45px; /* Más grande */
    padding: 5px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.btn-audio:hover {
    background: #1E3A6A;
}

/* Icono de audio más grande */
.btn-audio img {
    width: 100%;
    height: 100%;
}



/* Botón de búsqueda con lupa más grande */
.btn-buscar {
    background: transparent;
    border: none;
    position: absolute;
    right: 5px; /* Ajuste de posición */
    top: 50%;
    transform: translateY(-50%);
    width: 35px; /* Más grande */
    height: 35px; /* Más grande */
    cursor: pointer;
    padding: 0;
}

/* Imagen de la lupa más grande */
.btn-buscar img {
    width: 100%;
    height: 100%;
}
