:root {
    --primario: #4F46E5;
    --primario-hover: #4338CA;
    --fondo: #F3F4F6;
    --texto: #1F2937;
    --tarjeta: #FFFFFF;
    --borde: #E5E7EB;
}

body {
    font-family: 'Segoe UI', system-ui, sans-serif;
    background-color: var(--fondo);
    color: var(--texto);
    padding: 2rem 1rem;
    display: flex;
    justify-content: center;
    margin: 0;
}

.contenedor {
    background: var(--tarjeta);
    padding: 3rem;
    border-radius: 12px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 650px;
}

h2 {
    margin-top: 0;
    color: var(--primario);
    text-align: center;
    font-size: 1.8rem;
}

.controles-archivo {
    margin-bottom: 1.5rem;
    padding: 1.5rem;
    border: 2px dashed var(--borde);
    border-radius: 8px;
    text-align: center;
    background-color: #F9FAFB;
    transition: border-color 0.3s;
}

.controles-archivo:hover {
    border-color: var(--primario);
}

textarea {
    width: 100%;
    height: 250px;
    margin-bottom: 1.5rem;
    padding: 1rem;
    border: 1px solid var(--borde);
    border-radius: 8px;
    resize: vertical;
    font-size: 1rem;
    line-height: 1.6;
    box-sizing: border-box;
    background-color: #F9FAFB;
}

textarea:focus {
    outline: none;
    border-color: var(--primario);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.2);
}

.controles-reproduccion {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

button {
    flex: 1;
    padding: 0.5rem 1rem;
    background-color: var(--tarjeta);
    border: 1px solid var(--borde);
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    color: var(--texto);
    transition: all 0.2s;
    min-width: 100px;
}

button:hover {
    background-color: var(--primario);
    color: white;
    border-color: var(--primario);
}

#btn-leer {
    background-color: var(--primario);
    color: white;
    border-color: var(--primario);
}

#btn-leer:hover {
    background-color: var(--primario-hover);
}

.control-velocidad {
    background: var(--fondo);
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid var(--borde);
}

.control-velocidad label {
    display: block;
    margin-bottom: 0.8rem;
    font-weight: 500;
    font-size: 0.95rem;
}

input[type="range"] {
    width: 100%;
    accent-color: var(--primario);
    cursor: pointer;
}
/* Estilo general del texto del input (el nombre del archivo seleccionado) */
input[type="file"] {
    font-family: inherit;
    color: var(--texto);
    cursor: pointer;
}

/* Estilo exclusivo del botón "Seleccionar archivo" */
input[type="file"]::file-selector-button {
    padding: 0.5rem 1rem;
    margin-right: 1rem;
    background-color: var(--primario);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.2s;
}

/* Efecto al pasar el mouse por encima */
input[type="file"]::file-selector-button:hover {
    background-color: var(--primario-hover);
}
.control-filtro {
    margin-bottom: 1.5rem;
}

.control-filtro label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    font-size: 0.95rem;
}

.control-filtro input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--borde);
    border-radius: 6px;
    font-size: 1rem;
    box-sizing: border-box;
    background-color: #F9FAFB;
}

.control-filtro input:focus {
    outline: none;
    border-color: var(--primario);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.2);
}