/* 全体 */
body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  min-height: 100vh;
  font-family: "Hiragino Mincho ProN", serif;
  text-align: center;

  /* 背景はそのまま表示 */
  background-image: url("images/bg.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;

  display: flex;
  justify-content: center;
  align-items: center;
}

/* 中央パネル（文字可読性用） */
.container {
  background: rgba(255,255,255,0.7);
  padding: 28px 32px;
  border-radius: 18px;
  max-width: 270px;
  width: 90%;
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}

/* 見出し */
h1 {
  margin-top: 0;
  font-size: 22px;
}

.lead {
  font-size: 14px;
  margin-bottom: 18px;
}

/* カード */
#card {
  width: 280px;
  aspect-ratio: 5 / 8;
  margin: 0 auto;
  background-image: url("images/back.png");
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  cursor: pointer;
  transition: transform 0.4s;
}

#card.flip {
  transform: scaleX(0);
}

/* メッセージ */
#message {
  margin-top: 18px;
  font-size: 18px;
  line-height: 1.6;
}

/* リセットボタン */
button {
  display: none;
  margin-top: 16px;
  padding: 8px 18px;
  font-size: 14px;
  cursor: pointer;
}

/* 講座ボタン */
.course-btn {
  display: block;
  margin-top: 22px;
  padding: 14px;
  background: #cfefff;
  color: #000;
  text-decoration: none;
  border-radius: 14px;
  font-weight: bold;
  transition: background 0.3s;
}

.course-btn:hover {
  background: #e7b35f;
}

/* スマホ最適化 */
@media (max-width: 600px) {

  h1 {
    font-size: 20px;
  }

  #card {
    width: 270px;
  }

  #message {
    font-size: 14px;
  }

  .course-btn {
    font-size: 14px;
    padding: 12px;
  }
@media (max-width: 600px) {
  
#card {
  display: block;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}
html, body {
margin: 0;
  padding: 0;
  overflow-x: hidden;
}
}
