@import url('https://fonts.googleapis.com/css2?family=Comic+Relief:wght@400;700&display=swap');

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: "Comic Relief", system-ui;
  background-color: #f9fafb;
  color: #333;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.site-header {
  background-color: #ffffff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  padding: 10px 20px;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap; /* Tambahan agar tidak tumpang tindih di layar kecil */
  gap: 10px;
}

.header-left h1 {
  font-size: 24px;
  color: #1f2937;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 15px;
  flex-wrap: wrap;
}

.button-group {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.button-group button {
  padding: 8px 16px;
  font-size: 14px;
  border: none;
  border-radius: 6px;
  color: white;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  font-weight: bold;
}

.button-group button:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.15);
}

#btnanime {
  background: linear-gradient(90deg, hsla(46, 95%, 56%, 1) 0%, hsla(350, 97%, 65%, 1) 100%);
}

#btnFurry {
  background: linear-gradient(90deg, hsla(270, 91%, 83%, 1) 0%, hsla(290, 56%, 56%, 1) 100%);
}

.toggle-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: flex-end;
}

.toggle-switch {
  position: relative;
  width: 60px;
  height: 34px;
}

.toggle-switch input {
  display: none;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  border-radius: 34px;
  transition: 0.4s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  border-radius: 50%;
  transition: 0.4s;
}

input:checked + .slider {
  background-color: #2196F3;
}

input:checked + .slider:before {
  transform: translateX(26px);
}

.switch-label {
  font-size: 16px;
  color: #b10000;
}

.subtext-center {
  text-align: center;
  font-size: 14px;
  color: #6b7280;
  margin-top: 10px;
  margin-bottom: 30px;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: auto;
  text-align: center;
  padding: 20px;
  background: linear-gradient(90deg, hsla(266, 75%, 55%, 1) 0%, hsla(340, 47%, 77%, 1) 100%);
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.container span {
  cursor: default;
  color: #ffffffb9;
}

.image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); /* Lebih fleksibel untuk mobile */
  gap: 24px;
  margin-top: 25px;
}

.image-grid img {
  width: 100%; /* Gambar menyesuaikan lebar kolom */
  height: auto; /* Tinggi disesuaikan agar proporsional */
  object-fit: contain; /* Menampilkan seluruh gambar tanpa terpotong */
  border-radius: 10px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
  transition: transform 0.5s ease;
  cursor: pointer;
}

.image-grid img:hover {
  transform: scale(1.04);
}

.image-grid .iq-card {
  margin-bottom: 20px;
}

footer {
  background-color: #cdb4db;
  color: #f9fafb;
  text-align: center;
  padding: 10px;
  font-size: 15px;
  margin-top: auto;
  bottom: 0;
}

footer a {
  color: #af4ade;
  text-decoration: none;
  font-weight: bold;
}

footer a:hover {
  text-decoration: underline;
}

/* Tambahan untuk responsivitas lebih baik di layar kecil */
@media screen and (max-width: 600px) {
  .header-content {
    flex-direction: column;
    align-items: flex-start;
  }

  .header-right {
    justify-content: space-between;
    width: 100%;
  }

  .toggle-wrapper {
    justify-content: center;
  }
}
