html {
  scroll-behavior: smooth;
}
body {
    margin: 0;
    padding: 0;
    text-align: center;
  	font-family: "メイリオ", "Segoe UI", sans-serif;
  	background-color: #f5f7fb;
}
p {
	margin-left: 8%;
	margin-right: 8%;
}

.kouryu img{
		width: 300px;
	}
.renkei img{
		width: 300px;
	}
.efes img{
		width: 300px;
	}
.singaku img{
		width: 300px;
	}
/*ここスマホですか？？？？スマホですよ ありがとう！！！！！*/
@media screen and (max-width: 768px) {
	body {
    margin: 0;
    padding: 0;
    text-align: center;
  	font-family: "メイリオ", "Segoe UI", sans-serif;
  	background-color: #f5f7fb;
	}
	p {
		margin-left: 14%;
		margin-right: 14%;
	}
	.pc {
	  display: none;
	}
	.sf {
	  display: inline;
	}
	.f {
	  padding-bottom: 5px;
	}
	.kouryu img{
		max-width: 100%
	}
	.renkei img{
		max-width: 100%
	}
	.efes img{
		max-width: 100%
	}
	.singaku img{
		max-width: 100%
	}
}
.efes_img {
  display: block;   /* 画像をブロック要素にする */
  margin-bottom: 10px; /* 下に余白をつける */
}
/* containerとその中の要素のスタイル */
#container {
	position: relative;
	height: 250px;
	}
#btn {
	position: absolute;
	left: 50%;
	top: 50%;
	transform: translate(-50%, -50%);
	}
#efes_setumei {
	display: none;
	position: absolute;
	left: 50%;
	top: 60%;
	transform: translateX(-50%);
	text-align: center;
	width: 80%;
	}
#backBtn {
	display: none;
	position: absolute;
	left: 50%;
	top: 20px;
	transform: translateX(-50%);
	}
/* 全問題数表示エリア */
.quiz-info {
  font-size: 1.2rem;
  color: white;
  margin-bottom: 20px;
  max-width: 100px;
  margin-left: auto;
  margin-right: auto;
  padding: 5px;
  border: 2px solid #333;
  border-radius: 5px;
  background-color: dimgrey;
}

.quiz-container,
.result-section,
.final-section {
  display: none;
  margin: 20px auto;
}

.question-number {
  font-weight: bold;
  margin-bottom: 10px;
}

.question {
  font-weight: bold;
  margin-bottom: 10px;
  padding: 15px;
  border: 2px solid black;
  border-radius: 10px;
  box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.5);
  background-color: #ffffff;
}

.grid-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-gap: 10px;
}

.choice {
  padding: 15px;
  background-color: #ffffff;
  text-align: center;
  cursor: pointer;
  border: 2px solid black;
  border-radius: 10px;
  box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.5);
  transition: background-color 0.3s;
}

.choice:hover {
  background-color: #d0d0d0;
}

.result-section {
  padding: 20px;
  border: 2px solid black;
  border-radius: 10px;
  box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.5);
  background-color: #f1f1f1;
}

#answer-result {
  font-size: 2rem;
  margin-bottom: 10px;
}

.correct {
  color: green;
}

.wrong {
  color: red;
}

#next-question {
  margin-top: 20px;
  padding: 10px;
  background-color: #e0e0e0;
  text-align: center;
  cursor: pointer;
  border: 2px solid black;
  border-radius: 10px;
  box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.5);
  transition: background-color 0.3s;
  max-width: 300px;
  margin-left: auto;
  margin-right: auto;
}

#next-question:hover {
  background-color: #d0d0d0;
}

.final-section {
  padding: 20px;
  border: 2px solid black;
  border-radius: 10px;
  box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.5);
  background-color: #f9f9f9;
  margin: 20px auto;
  max-width: 800px;
}

#restart-quiz {
  margin-top: 20px;
  padding: 10px;
  background-color: #e0e0e0;
  text-align: center;
  cursor: pointer;
  border: 2px solid black;
  border-radius: 10px;
  box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.5);
  transition: background-color 0.3s;
  max-width: 300px;
  margin-left: auto;
  margin-right: auto;
}

#restart-quiz:hover {
  background-color: #d0d0d0;
}

#b {
  position: fixed;
  bottom: 20px; /* 画面の下から20pxの位置に配置 */
  left: 50%;
  transform: translateX(-50%); /* 中央寄せ */
  background-color: #f0f0f0;
  padding: 10px 20px;
  border-radius: 10px;
  text-decoration: none;
  color: #333;
  font-weight: bold;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}
#b:hover {
  background-color: #ddd;
}

#a {
  background-color: rgba(173, 216, 230, 0.5); /* 水色 (lightblue) + 透明度50% */
}

h2{
	margin-top: 2%;
	margin-bottom:2%;
	margin-left:8%;
	margin-right:8%;
	background-color:khaki;
	padding: 1rem 2rem;
 	border-bottom: 3px solid #dcdcdc;
	border-left: 5px solid #000;
	background: #f4f4f4;
 	border-radius: 3px;
 	box-shadow: 0 0 8px rgba(0,0,0,.4);
 	text-align:center;
}
.midashi {
  position: relative;
  padding: 1rem .5rem;
  font-size: 40px;
  display: inline-block; /* アニメーションを適用するために必要 */
}

.midashi::after {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0%; /* 初期状態では幅を0に */
  height: 6px;
  content: '';
  border-radius: 3px;
  background-image: -webkit-gradient(linear, right top, left top, from(#2af598), to(#009efd));
  background-image: -webkit-linear-gradient(right, #2af598 0%, #009efd 100%);
  background-image: linear-gradient(to left, #2af598 0%, #009efd 100%);
  transition: width 1s ease-out; /* アニメーションの設定 */
}

/* ページ読み込み時にアニメーションを適用 */
.midashi.loaded::after {
  width: 100%; /* アニメーション後、幅が100%に */
}


mark{
font-size:16px;
background-color:gold;
}

.btn {
  padding: 15px 40px;
  font-size: 16px;
  font-weight: 600;
  color: white;
  background: #00ced1;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}
.btn::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(211, 222, 241, 0.5);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}
.btn:hover::after {
  width: 300px;
  height: 300px;
}
#back-top {
	position: fixed;
	bottom: 30px;
	right: 30px;
	width: 50px;
	height: 50px;
	border: none;
	border-radius: 50%;
	background-color: #0078ff;
	color: white;
	font-size: 20px;
	font-weight: bold;
	cursor: pointer;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
	opacity: 0;
	visibility: hidden;
	transition: all 0.4s ease;
	z-index: 1000;
}

#back-top:hover {
	background-color: #005fcc;
	transform: scale(1.1);
}
#back-top::after {
	content: "上に戻る";
	position: absolute;
	bottom: 60px; /* ボタンの上に表示 */
	left: 50%;
	transform: translateX(-50%);
	background: rgba(0, 0, 0, 0.5);
	color: #ADE8E6;
	font-size: 12px;
	padding: 4px 8px;
	border-radius: 6px;
	white-space: nowrap;
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.3s ease, transform 0.3s ease;
}

#back-top:hover::after {
	opacity: 1;
	transform: translateX(-50%) translateY(-5px);
}

#back-top.show {
	opacity: 1;
	visibility: visible;
}

#more a {
    background: #eee;
    position: relative;
    display: flex;
    justify-content: space-around;
    align-items: center;
    margin: 0 auto;
    max-width: 240px;
    padding: 10px 25px;
    color: #6699cc;
    transition: 0.3s ease-in-out;
    font-weight: 500;
    z-index:0;
    border-left: solid 5px #6699cc;
    text-decoration: none
}
    
#more a:before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    width: 0;
    display: block;
    background: #6699cc;
    transition: .3s;
    left:0;
}
#more a:hover {
    color: #FFF;
}
#more a:hover:before {
    width: 100%;
    z-index: -1;
}

#more {
	border: 2px solid #333;
	border-radius: 5px;
	padding: 30px;
	position: relative;
	background-color: #fff;
	width:300px;
	margin: 50px auto;
}

#more::before {
	background-color: #e0ffff;
	color: #333;
	content: "もっと行事を知りたいなら";
	font-weight: bold;
	left: 70px;
	padding: 3px 10px;
	position: absolute;
	top: -15px;
}

.meisi {
	font-size: 23px;
	padding: 0;
}

.sen {
	font-size: 20px;
}