body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  background-color: #061271;
  font-family: Arial, sans-serif;
  color: #ffffff;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

.container {
  text-align: center;
  max-width: 600px;
  width: 90%;
  margin: 0 auto;
}

#reloadBtn {
  background-color: #ffffff;
  border: none;
  color: #000000;
  font-size: 24px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  margin-bottom: 20px;
}

#reloadBtn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

#searchInput {
  width: 100%;
  padding: 12px 16px;
  font-size: 16px;
  border-radius: 20px;
  border: none;
  outline: none;
  background-color: #ffffff;
  color: #000000;
  margin-bottom: 20px;
}

.button-row {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.button-row a,
.button-row button {
  background-color: #ffffff;
  color: #000000;
  border: none;
  padding: 12px 24px;
  border-radius: 20px;
  font-size: 16px;
  cursor: pointer;
  text-decoration: none;
}

.button-row button:hover,
.button-row a:hover,
#reloadBtn:hover {
  opacity: 0.85;
}

.icon-button {
  background-color: #ffffff;
  border: none;
  border-radius: 20px;
  padding: 12px;
  margin: 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease;
}

.icon-button:hover {
  background-color: #dddddd;
}

.icon-button svg {
  width: 24px;
  height: 24px;
  stroke: #000000;
  stroke-width: 2;
}

#buttonGroup {
  display: flex;
  justify-content: center;
  gap: 16px; /* spacing between buttons */
  margin-top: 20px;
}

#gifDisplay {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  border-radius: 20px;
  display: block;
  object-fit: contain;
  margin: 0 auto;
}

#gifContainer {
  width: 90vw;
  max-width: 600px;
  height: 60vh; /* Fixed height so layout stays consistent */
  margin: 20px auto;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  background-color: transparent; /* or add a subtle color if you'd like */
}

@media (max-width: 600px) {
  #gifContainer {
    height: 40vh;
  }

  #searchInput {
    width: 80%;
    font-size: 1rem;
    padding: 10px;
    border-radius: 12px;
  }

  .icon-button {
    padding: 10px;
    border-radius: 16px;
  }

  #buttonGroup {
    flex-direction: column;
    align-items: center;
    gap: 12px;
    margin-top: 10px;
  }

  #reloadBtn {
    margin: 10px auto;
    padding: 10px;
  }
}

/* Spinner animation */
@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}