:root {
  color-scheme: light;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.45;
  color: #172033;
  background: #f1f5f9;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  min-width: 280px;
  margin: 0;
}

.contenedor {
  width: min(100% - 1.25rem, 42rem);
  margin-inline: auto;
}

.barra-superior {
  margin-bottom: 1rem;
  color: #fff;
  background: #155e75;
  box-shadow: 0 2px 8px rgb(15 23 42 / 16%);
}

.encabezado {
  display: flex;
  min-height: 4rem;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: 1.45rem;
}

h2 {
  margin-bottom: 0.85rem;
  font-size: 1.2rem;
}

.tarjeta {
  margin-bottom: 1rem;
  padding: 1rem;
  border: 1px solid #dbe4ee;
  border-radius: 0.8rem;
  background: #fff;
  box-shadow: 0 2px 5px rgb(15 23 42 / 6%);
}

.estado-inicial {
  text-align: center;
}

label {
  display: block;
  margin: 0.8rem 0 0.3rem;
  font-weight: 650;
}

input,
button {
  min-height: 3rem;
  border-radius: 0.55rem;
  font: inherit;
}

input {
  width: 100%;
  padding: 0.65rem 0.75rem;
  border: 1px solid #94a3b8;
  color: #172033;
  background: #fff;
}

input:focus,
button:focus-visible {
  outline: 3px solid #67e8f9;
  outline-offset: 2px;
}

button {
  border: 0;
  padding: 0.65rem 1rem;
  cursor: pointer;
  font-weight: 700;
}

button:disabled {
  cursor: wait;
  opacity: 0.62;
}

.boton-principal {
  width: 100%;
  margin-top: 1rem;
  color: #fff;
  background: #0e7490;
}

.boton-principal:hover:not(:disabled) {
  background: #155e75;
}

.boton-secundario {
  border: 1px solid rgb(255 255 255 / 75%);
  color: #fff;
  background: transparent;
}

.compacto {
  min-height: 2.55rem;
  padding: 0.4rem 0.65rem;
  font-size: 0.86rem;
}

.boton-texto {
  min-height: 2.5rem;
  padding: 0.35rem 0.5rem;
  color: #0e7490;
  background: transparent;
}

.texto-secundario,
.etiqueta {
  color: #526174;
}

.etiqueta {
  margin-bottom: 0.25rem;
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.mensaje {
  margin: 0.9rem 0 0;
  padding: 0.75rem;
  border-radius: 0.5rem;
  background: #e0f2fe;
}

.error {
  color: #8a1c1c;
  background: #fee2e2;
}

.confirmacion {
  border-color: #86efac;
  background: #f0fdf4;
}

.confirmacion h2 {
  color: #166534;
}

.dato-destacado {
  margin-bottom: 0.2rem;
  font-size: 1.12rem;
  font-weight: 750;
}

.lista-resultados,
.lista-recientes {
  margin: 0.8rem 0 0;
  padding: 0;
  list-style: none;
}

.lista-resultados li,
.lista-recientes li {
  padding: 0.8rem 0;
  border-top: 1px solid #e2e8f0;
}

.resultado {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.resultado p,
.lista-recientes p {
  margin-bottom: 0.1rem;
}

.seleccionar {
  flex: none;
  border: 1px solid #0e7490;
  color: #0e7490;
  background: #fff;
}

.accion-principal {
  margin-top: 1.25rem;
  font-size: 1.04rem;
}

.titulo-con-accion {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.titulo-con-accion h2 {
  margin-bottom: 0;
}

.solo-lectores {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

@media (min-width: 36rem) {
  .formulario-busqueda {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.65rem;
  }

  .formulario-busqueda .boton-principal {
    width: auto;
    margin-top: 0;
  }
}
