:root {
  --bg-color: #FFFDF0;       /* 優しいアイボリー白 */
  --primary-yellow: #FFD500; /* テーブルクロスの元気な黄 */
  --primary-blue: #00A6EB;   /* ブースの鮮やかな水色 */
  --accent-red: #FF5A5F;     /* 旗の赤 */
  --accent-green: #7BC043;   /* 旗の黄緑 */
  --accent-orange: #FF8A00;  /* 宝箱のオレンジ */
  --text-main: #333333;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'M PLUS Rounded 1c', 'Hiragino Maru Gothic ProN', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.6;
}

/* ガーランド（三角旗） */
.garland-container {
  display: flex;
  justify-content: center;
  overflow: hidden;
  background: #ffffff;
  padding-bottom: 8px;
  border-bottom: 3px solid #eee;
}

.flag {
  width: 0;
  height: 0;
  border-left: 20px solid transparent;
  border-right: 20px solid transparent;
  border-top: 30px solid;
  margin: 0 4px;
}
.flag-blue { border-top-color: var(--primary-blue); }
.flag-yellow { border-top-color: var(--primary-yellow); }
.flag-red { border-top-color: var(--accent-red); }
.flag-green { border-top-color: var(--accent-green); }
.flag-orange { border-top-color: var(--accent-orange); }

/* ヘッダー */
.hero {
  text-align: center;
  padding: 40px 20px 20px;
}

.badge {
  display: inline-block;
  background: #FFF;
  border: 3px solid var(--accent-orange);
  color: var(--accent-orange);
  font-weight: 800;
  padding: 6px 18px;
  border-radius: 30px;
  font-size: 0.95rem;
  margin-bottom: 12px;
  box-shadow: 0 4px 0 rgba(0,0,0,0.05);
}

.hero-title {
  font-size: 2.2rem;
  font-weight: 900;
  color: #222;
  margin-bottom: 15px;
}

.highlight {
  color: #E65100;
  background: linear-gradient(transparent 65%, #FFE082 65%);
}

.hero-desc {
  font-size: 1.05rem;
  color: #555;
}

/* メインコンテナ */
.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 20px;
}

/* クイズカードグリッド */
.quiz-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 20px;
}

.quiz-card {
  display: flex;
  flex-direction: column;
  background: #FFFFFF;
  border-radius: 20px;
  padding: 24px;
  text-decoration: none;
  color: var(--text-main);
  border: 4px solid;
  box-shadow: 0 8px 0 rgba(0,0,0,0.08);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  position: relative;
}

.quiz-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 0 rgba(0,0,0,0.1);
}

.card-yellow { border-color: var(--primary-yellow); }
.card-blue { border-color: var(--primary-blue); }
.card-green { border-color: var(--accent-green); }
.card-orange { border-color: var(--accent-orange); }

.card-num {
  font-weight: 900;
  font-size: 1rem;
  color: #888;
}

.card-icon {
  font-size: 2.2rem;
  margin: 8px 0;
}

.card-title {
  font-size: 1.15rem;
  font-weight: 800;
  margin-bottom: 15px;
  flex-grow: 1;
}

.card-choices {
  background: #F9F9F9;
  border-radius: 10px;
  padding: 10px;
  font-size: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 16px;
  color: #666;
}

.card-btn {
  text-align: center;
  font-weight: 800;
  background: #FFF9C4;
  color: #D84315;
  padding: 10px;
  border-radius: 12px;
  border: 2px dashed #FFA000;
}

/* クイズ個別ページ */
.quiz-container {
  max-width: 680px;
}

.navigation-top {
  margin-bottom: 20px;
}

.back-link {
  color: var(--primary-blue);
  text-decoration: none;
  font-weight: 800;
  font-size: 1rem;
}

.quiz-play-box {
  background: #FFFFFF;
  border-radius: 25px;
  border: 5px solid var(--primary-blue);
  padding: 35px 25px;
  box-shadow: 0 10px 0 #D0E8F5;
  text-align: center;
}

.quiz-badge {
  display: inline-block;
  background: var(--primary-yellow);
  color: #000;
  font-weight: 900;
  padding: 4px 16px;
  border-radius: 20px;
  font-size: 1.1rem;
  margin-bottom: 15px;
}

.quiz-question {
  font-size: 1.4rem;
  font-weight: 800;
  margin-bottom: 10px;
  line-height: 1.5;
}

.quiz-subtext {
  color: #777;
  font-size: 0.95rem;
  margin-bottom: 30px;
}

.choice-buttons {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-bottom: 20px;
}

.choice-btn {
  font-family: inherit;
  font-size: 1.15rem;
  font-weight: 800;
  padding: 18px 20px;
  background: #FFF;
  border: 3px solid var(--primary-blue);
  border-radius: 15px;
  cursor: pointer;
  box-shadow: 0 5px 0 #B3E5FC;
  transition: all 0.1s ease;
}

.choice-btn:hover:not(:disabled) {
  background: #E1F5FE;
  transform: translateY(-2px);
  box-shadow: 0 7px 0 #B3E5FC;
}

.choice-btn:active:not(:disabled) {
  transform: translateY(3px);
  box-shadow: 0 2px 0 #B3E5FC;
}

.choice-btn:disabled {
  opacity: 0.6;
  cursor: default;
}

/* 回答結果エリア */
.result-box {
  margin-top: 30px;
  padding: 25px;
  border-radius: 20px;
  background: #FFFDF0;
  border: 3px dashed var(--accent-orange);
  text-align: left;
}

.result-status {
  text-align: center;
  font-size: 1.8rem;
  font-weight: 900;
  margin-bottom: 12px;
}
.result-status.correct { color: #E64A19; }
.result-status.incorrect { color: #0288D1; }

.result-title {
  font-size: 1.25rem;
  font-weight: 800;
  margin-bottom: 10px;
  color: #222;
}

.result-explanation {
  font-size: 1rem;
  margin-bottom: 15px;
}

.source-info {
  font-size: 0.8rem;
  color: #888;
  border-top: 1px solid #E0E0E0;
  padding-top: 8px;
  margin-bottom: 20px;
}

.action-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.main-btn, .sub-btn {
  font-family: inherit;
  padding: 12px 24px;
  border-radius: 12px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

.main-btn {
  background: var(--primary-blue);
  color: #fff;
  border: none;
}

.sub-btn {
  background: #eee;
  color: #333;
  border: none;
}

/* フッター */
.footer {
  text-align: center;
  padding: 30px 10px;
  color: #999;
  font-size: 0.85rem;
}