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

h1 {
  font-size: clamp(20px, 4vw, 40px);
  margin-top: 3vw;
  margin-bottom: 0;
}

.hand-container {
  position: relative;
  width: 60vw; /* 相對於畫面寬度 */
  max-width: 400px;
  margin: 0 auto;
  margin-top: 20px;
}

.hand-img {
  width: 100%;
  height: auto;
  display: block;
}

/* 六壬項目位置（使用絕對定位，但會根據容器縮放） */
.point {
  position: absolute;
  color: #333;
  font-weight: bold;
  font-size: clamp(14px, 2vw, 22px); /* 電腦上變小、手機上保留可讀性 */
  text-align: center;
  line-height: 1.2;
  transition: all 0.3s ease-in-out;
}

@media (max-width: 600px) {
  .point {
    font-size: 4vw; /* 小螢幕保持可讀性 */
  }
}

.point.highlight {
  color: #fff;
  background: #ff9900;
  border-radius: 50%;
  padding: 0.3em;
  transform: scale(1.3);
}

.floating-step {
  position: absolute;
  top: 70%;
  left: 60%;
  transform: translateX(-50%);
  font-size: clamp(20px, 7vw, 45px);  /* 隨畫面自動縮放 */
  font-weight: bold;
  color: rgba(0, 0, 0, 0.2);  /* 浮水印感覺 */
  pointer-events: none;
  user-select: none;
  white-space: nowrap;
}

button {
  font-size: 1.2rem;
  padding: 1rem 2rem;
  border-radius: 1rem;
  border: none;
  background-color: #4CAF50;
  color: white;
  cursor: pointer;
}

.result {
  margin-top: 2rem;
  font-size: 1.2rem;
}


.modal {
  position: fixed;
  z-index: 999;
  left: 0; top: 0;
  width: 100%; height: 100%;
  background-color: rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-content {
  background-color: #fff;
  padding: 1.5rem;
  max-width: 90%;
  width: 400px;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  position: relative;
  text-align: left;
  font-size: 0.9rem;
  line-height: 1.6;
  color: #333;
}

.modal .close {
  position: absolute;
  right: 1rem;
  top: 1rem;
  font-size: 1.2rem;
  cursor: pointer;
}

