/* 🎨 recycle-game/style.css 共用樣式表 */

body {
  font-family: 'Noto Sans TC', sans-serif;
  margin: 0;
  background-color: #f4f8f7;
  color: #333;
  text-align: center;
}

header {
  background-color: #2a7b6f;
  color: #fff;
  padding: 10px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 10;
}

h1, h2 {
  margin: 10px 0;
}

.menu-button {
  font-size: 24px;
  cursor: pointer;
  background: none;
  border: none;
  color: white;
}

nav {
  display: none;
  position: absolute;
  top: 60px;
  right: 20px;
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  text-align: left;
  min-width: 160px;
}

nav a {
  display: block;
  padding: 10px 20px;
  color: #2a7b6f;
  text-decoration: none;
  font-weight: 500;
}

nav a:hover {
  background-color: #e0f2ef;
}

main {
  padding: 20px;
  margin-top: 20px;
}

button {
  background-color: #2a7b6f;
  color: white;
  border: none;
  border-radius: 8px;
  padding: 10px 20px;
  margin: 10px;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.2s;
}

button:hover {
  background-color: #206257;
}

#gameArea {
  margin-top: 30px;
  padding: 20px;
  background-color: white;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  display: inline-block;
}

#item {
  font-size: 48px;
  margin-bottom: 20px;
}

#bins button {
  font-size: 18px;
}

#result {
  font-size: 20px;
  font-weight: bold;
  margin-top: 20px;
}

ul {
  list-style-type: none;
  padding: 0;
}

ul li {
  background: white;
  margin: 10px auto;
  padding: 12px 16px;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  max-width: 480px;
}

/* 小螢幕適配 */
@media (max-width: 600px) {
  header {
    flex-direction: column;
    align-items: flex-start;
  }
  nav {
    right: 10px;
    top: 70px;
  }
  #gameArea {
    width: 90%;
  }
  .img-box {
  width: 120px;       /* 容器寬度固定 */
  height: 120px;      /* 容器高度固定 */
  display: inline-flex;
  justify-content: center;
  align-items: center;
  margin: 6px;
  border-radius: 8px;
  border: 2px solid #ddd;
  background-color: #fff;
}

.img-box img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain; /* 保持圖片比例，不會變形 */
}
}
