* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: sans-serif;
    font-weight: 400;
    line-height: 1.75;
    background: #f8fafc;
    color: #0f172a;
}

p {
    margin-bottom: 1.5rem;
    max-width: 40em;
}

h3, h4 {
    margin: 0;
    margin-bottom: 1.38rem;
    font-weight: 400;
    line-height: 1.3;
    text-transform: capitalize;
    letter-spacing: 1px;
}

h3 {
    font-size: 1.953rem;
}
  
h4 {
    font-size: 1.563rem;
}

a {
    text-decoration: none;
}

.img {
    width: 100%;
    display: block;
    object-fit: cover;
}

.loading {
    margin: 0 auto;
    margin-top: 4rem;
    width: 6rem;
    height: 6rem;
    border: 5px solid #94a3b8;
    border-radius: 50%;
    border-top-color: #645cff;
    animation: spinner 0.6s linear infinite;
}

@keyframes spinner {
    to {
      transform: rotate(360deg);
    }
}

.title {
    text-align: center;
    margin-bottom: 3rem;
}
  
.title-underline {
    background: #645cff;
    width: 7rem;
    height: 0.25rem;
    margin: 0 auto;
    margin-top: -1rem;
}

.wikipedia {
    padding: 5rem 0;
    width: 90vw;
    max-width: 1170px;
    margin: 0 auto;
}

.container {
    text-align: center;
}

.container img {
    width: 200px;
}

.container h3 {
    margin-bottom: 2rem;
}

.formulario {
    background: #fff;
    width: 100%;
    margin: 0 auto;
    padding: 2.5rem;
    border-radius: 0.25rem;
    display: grid;
    grid-template-columns: auto 100px;
}

.formulario-input, .submit-btn {
    padding: 0.375rem 0.75rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}

.formulario-input {
    border-right: transparent;
    border-top-left-radius: 0.25rem;
    border-bottom-left-radius: 0.25rem;
}

.submit-btn {
    border: 1px solid #645cff;
    border-left: transparent;
    border-top-right-radius: 0.25rem;
    border-bottom-right-radius: 0.25rem;
    text-transform: capitalize;
    background: #645cff;
    color: #fff;
    transition: 0.3s ease-in-out all;
    cursor: pointer;
}

.submit-btn:hover {
    color: #141233;
}

.resultados {
    padding: 2rem 0;
}

.erros {
    text-align: center;
    text-transform: capitalize;
    color: #842029;
}

.artigos {
    display: grid;
    gap: 1rem;
}

.artigos a {
    display: block;
    background: #fff;
    color: #0f172a;
    padding: 1.5rem 2rem;
    border-radius: 0.25rem;
    transition: 0.3s ease-in-out all;
}

.artigos a:hover {
    background: #222;
    color: #fff;
}

.artigos p {
    color: #64748b;
    transition: 0.3s ease-in-out all;
}

@media screen and (min-width: 768px) {
    .artigos {
      grid-template-columns: 1fr 1fr;
    }
    
    .formulario {
      max-width: 600px;
    }
}

@media screen and (min-width: 992px) {
    .artigos {
      grid-template-columns: 1fr 1fr 1fr;
    }
}