* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
}

body {
  background: radial-gradient(circle at center, #7d0301, #000000);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  align-items: center;
}

.main-title {
  font-size: 2.5rem;
  text-align: center;
  margin-bottom: 2rem;
  color: rgb(255, 255, 255);
}

.grid-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  padding: 50px 1vw;
  width: 100%;
  max-width: 1400px;
}

.grid-item {
  background: rgba(7, 0, 101, 0.2);
  padding: 1rem;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(255, 0, 0, 0.3);
  border: 1px solid rgb(221, 78, 104);
  width: 100%;
  min-width: 200px;
  min-height: 200px;
  overflow: hidden;
}

.grid-item h2 {
  font-size: 1.25rem;
  margin-bottom: 15px;
  color: white;
  text-align: center;
}

.grid-item button {
  padding: 0.5rem 1rem;
  background-color: #6830cf;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  margin-bottom: 1rem;
  width: 100%;
}

.grid-item button:hover {
  background-color: rgb(233, 49, 49);
}

.output {
  margin-top: 0.5rem;
}

img {
  max-width: 100%;
  height: auto;
  border-radius: 5px;
  margin-top: 0.5rem;
}

/* Joke */

#joke-output {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

#JokeQ {
  font-weight: 600;
  background-color: white;
  padding: 15px 15px 10px 15px;
  border-radius: 5px 5px 0px 0px;
  font-size: 1rem;
  color: rgb(0, 0, 0);
  width: 100%;
  text-align: center;
}

#JokeA {
  margin-bottom: 10px;
  font-weight: 600;
  background-color: #000000;
  padding: 15px 15px 15px 15px;
  border-radius: 0px 0px 10px 10px;
  font-size: 1rem;
  color: white;
  width: 100%;
  text-align: center;
  border: solid 5px white;
}

/* Emoji */

#emoji-output {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

#emoji-size {
  font-size: 100px;
}

/* Movies */

#movies-api {
  grid-column: 1 / -1;
}

.carousel-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
}

#movies-output.carousel {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding: 20px 0;
  scroll-snap-type: x mandatory;
  width: 100%;
  min-width: 0;
}

#movies-output.carousel > div {
  scroll-snap-align: start;
  flex: 0 0 auto;
  display: flex;
}

#prevBtn,
#nextBtn {
  background-color: #6830cf;
  color: white;
  border: none;
  border-radius: 4px;
  padding: 10px 20px;
  cursor: pointer;
  width: fit-content;
}

#prevBtn:hover,
#nextBtn:hover {
  background-color: rgb(233, 49, 49);
}
#movie-card {
  display: flex;
  flex-direction: column;
  width: 200px;
}

#movies-output {
  display: flex;
}

#movie-poster {
  width: auto;
  height: 300px;
  object-fit: cover;
  border-radius: 10px 10px 0px 0px;
  align-items: stretch;
}

#movie-title {
  font-size: 11px;
  text-transform: uppercase;
  max-width: 100%;
  font-weight: 500;
  letter-spacing: 1px;
  line-height: 15px;
  background-color: #00000078;
  color: rgb(236, 86, 86);
  border-radius: 0px 0px 10px 10px;
  padding: 15px 15px;
  text-align: center;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Weather API Output */
input {
  padding: 0.5rem;
  width: 100%;
  font-size: 1rem;
  margin-bottom: 0.75rem;
  border: 1px solid #ccc;
  border-radius: 4px;
}

#weather-output {
  font-size: 1rem;
  padding: 0.75rem 1rem;
  background-color: #e6f7ff;
  border: 1px solid #b3e5fc;
  border-radius: 6px;
  min-height: 2.5rem;
  color: #333;
}

.weather-icon {
  vertical-align: middle;
  width: 40px;
  height: 40px;
}

/* Currency Rates Output */
#currency-output {
  font-size: 1rem;
  color: #333;
  background-color: #f0f8ff;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  border: 1px solid #cce5ff;
  min-height: 2.5rem;
}
#currency-api input {
  padding: 0.5rem;
  width: 100%;
  font-size: 1rem;
  margin-bottom: 0.75rem;
  border: 1px solid #ccc;
  border-radius: 4px;
}
#currency-api select {
  padding: 0.5rem;
  width: 100%;
  font-size: 1rem;
  margin-bottom: 0.75rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  background-color: #fff;
}

/* GitHub */

#github-users {
  display: flex;
  flex-direction: row;
}

#github-output {
  color: white;
  margin-top: 3px;
  display: block;
}

#github-output p a {
  border-radius: 5px;
  padding: 10px;
  background-color: #6830cf;
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
  display: block;
  margin-top: 10px;
}

#github-output p a:hover {
  background-color: #ffffff;
  color: #6830cf;
}
