.wq-contents {
	display: flex;
	position: relative;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
}

.wq-contents.top {
	background: no-repeat center center / 100% 100%;
}

.wq-contents:not(.top) {
	background:
		linear-gradient(0deg, white, white) no-repeat center center / calc(100% - 1em) calc(100% - 9.96em),
		linear-gradient(0deg, rgba(255,255,255,0.6), rgba(255,255,255,0.6)) no-repeat center center / 100% calc(100% - 9.96em);
}

.wq-contents:not(.top)::before,
.wq-contents:not(.top)::after {
	content: '';
	display: block;
	position: absolute;
	left: 0;
	width: 100%;
	height: 5em;
	background: no-repeat;
	background-size: 100% auto;
}
.wq-contents:not(.top)::before {
	top: 0;
	background-position: center top;
}
.wq-contents:not(.top)::after {
	bottom: 0;
	background-position: center bottom;
}

.wq-contents > * {
	position: relative;
	z-index: 1;
}


.wq-contents h2 {
	position: absolute;
	left: 0;
	top: 0;
	width: 100%;
	margin: 0;
	font-size: inherit;
	text-align: center;
}


@media (max-width: 640px) {
	.wq-contents.top {
		width: 23em;
		height: 17em;
		margin-top: 4.5em;
		padding-top: 2em;
		background-image: url(../images/common/base_top_sp.png);
	}

	.greeting .wq-contents.top h2 {
		transform: translateY(-4.75em);
	}
	.flag .wq-contents.top h2 {
		transform: translateY(-4em);
	}
	.wq-contents.top h2 img {
		font-size: 90%;
	}

	.wq-contents:not(.top) {
		width: 23em;
		margin-top: 4em;
		padding-top: 4em;
	}
	.wq-contents:not(.top)::before,
	.wq-contents:not(.top)::after {
		background-image: url(../images/common/base_contents_sp.png);
	}
	
	.wq-contents:not(.top) h2 {
		transform: translateY(-50%);
	}


}


@media (min-width: 641px) {
	.wq-contents.top {
		width: 38em;
		height: 19em;
		margin-top: 1.5em;
		padding-top: 2em;
		background-image: url(../images/common/base_top_pc.png);
	}

	.greeting .wq-contents.top h2 {
		transform: translateY(-2.25em);
	}
	.flag .wq-contents.top h2 {
		transform: translateY(-1.5em);
	}

	.wq-contents:not(.top) {
		margin-top: 1em;
		padding-top: 3em;
		width: 45em;
	}

	.wq-contents:not(.top)::before,
	.wq-contents:not(.top)::after {
		background-image: url(../images/common/base_contents_pc.png);
	}
	/* for meiji css */
	.wq-contents:not(.top)::after {
		visibility: visible;
	}

	.wq-contents:not(.top) h2 {
		transform: translateY(-30%);
	}
}


.finish .result {
	display: flex;
	position: relative;
	flex-direction: column;
	align-items: center;
	box-sizing: border-box;
	border-radius: 1em;
	padding: 1em;
}
.finish .result.correct {
	background: #faeeaf;
}
.finish .result.incorrect {
	background: #cfeafa;
}

.finish .result .qnum {
	position: absolute;
	left: 0;
	top: 0;
	width: 100%;
	text-align: center;
	transform: translateY(-50%);
}

.finish .result .judge {
	margin-top: 1.5em;
}

.flag .finish .q {
	margin-top: 1.5em;
	width: 70%;
}
.flag .finish .result .judge {
	margin-top: 0.5em;
}

.finish .result .answer {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	margin-top: 0.5em;
}

.finish .result.correct .answer > *:not(.correct_answer) {
	display: none;
}

.finish .result .wc-link {
	width: 100%;
}

.greeting .finish .result .wc-link {
	margin-top: 1.5em;
}

.finish .result .wc-link img {
	width: 100%;
}

.finish .replay {
	margin: 2.5em 0 0;
}
.flag .finish .replay {
	margin-bottom: 2.5em;
}

.finish .link {
	margin: 2.5em 0;
}
.finish .link a:hover img {
	transform: scale(1.05);
	transition: 200ms;
}

@media (max-width: 640px) {

	.finish .rank img {
		font-size: 85%;
	}

	.finish .results {
		margin-top: 1em;
	}

	.finish .result {
		margin: 2em 1.5em 0;
	}

	.finish .result .answer .correct_is img {
		font-size: 150%;
	}
	.finish .result .answer .correct_answer img {
		font-size: 125%;
	}

	.finish .result .judge img {
		font-size: 150%;
	}



}


@media (min-width: 641px) {

	.finish .rank {
		margin: 1em auto;
	}
	.finish .rank img {
		font-size: 85%;
	}

	.finish .results {
		display: flex;
		flex-wrap: wrap;
		justify-content: center;
		margin: 1em auto 0;
		width: calc(100% - 4em);
	}

	.finish .judge {
		display: flex;
		align-items: center;
		justify-content: center;
		height: 2.5em;
	}
	.finish .judge::after {
		content: none;
	}

	.finish .result {
		margin: 2em 1% 0;
		width: 31%;
	}

	.finish .result:nth-of-type(4) {
		margin-left: 10%;
	}
	.finish .result:nth-of-type(5) {
		margin-right: 10%;
	}

	.greeting .finish .result .answer {
		height: 11em;
	}
	.flag .finish .result .answer {
		height: 10em;
	}

	.finish .result.incorrect .answer .correct_is {
		height: 8%;
	}
	.greeting .finish .result.incorrect .answer .user_answer {
		height: 38%;
	}
	.greeting .finish .result.incorrect .answer .correct_answer {
		height: 54%;
	}

	.flag .finish .result.incorrect .answer .user_answer {
		height: 40%;
	}
	.flag .finish .result.incorrect .answer .correct_answer {
		height: 52%;
	}

	.finish .result .answer > div {
		font-size: 0;
	}

	.finish .result.incorrect .answer img {
		width: auto;
		max-height: 100%;
	}



}


.wq-judge {
	display: flex;
	position: absolute;
	z-index: 2;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
}

.wq-judge > * {
	position: absolute;
	left: 50%;
	top: 40%;
	transform: translate(-50%, -50%);
}

.wq-judge img {
	max-width: none;
}

.greeting .wq-judge .text {
	margin-top: 6.5em;
}
.greeting .wq-judge .text img {
	font-size: 65%;
}

.flag .wq-judge .answer {
	margin-top: 1.5em;
}


.play .q_num {
	margin: 1em 0 2em;
	text-align: center;
}


@media (max-width: 640px) {
	.flag .play .q_num img {
		width: 85%;
	}
}


/* responsive */
@media (max-width: 640px) {
	.quiz-link,
	.quiz-link img {
		font-size: 4vw;
	}
}

@media (min-width: 641px) {
	.quiz-link,
	.quiz-link img {
		font-size: 20px;
	}
}


/* reset */
.quiz-link::after,
.quiz-link div::after,
.quiz-link dl::after,
.quiz-link ul::after {
	content: none;
}

.quiz-link {
	display: grid;
	grid-gap: 1em;
	justify-items: center;
	position: relative;
	width: max-content;
	margin: 1.5em auto;
	padding: 0 1.5em 1.5em;
	color: black;
}

body:not(.world-quiz-finished) .quiz-link {
	display: none;
}

.quiz-link::before {
	content: '';
	display: block;
	position: absolute;
	left: 0;
	bottom: 0;
	width: 100%;
	height: calc(100% - 1em);
	border-radius: 1.5em;
	background: #ffe3d6;
}

.quiz-link > * {
	position: relative;
}

.quiz-link img {
	vertical-align: bottom;
}

.quiz-link h2 {
	margin: 0;
}
.quiz-link h2 img {
	width: 19em;
}

.quiz-link ul {
	display: grid;
	margin: 0;
	padding: 0;
	list-style-type: none;
}

.quiz-link li {
	display: grid;
	justify-items: center;
	grid-gap: 0.5em;
}

.quiz-link figure {
	display: grid;
	grid-gap: 0.5em;
	justify-items: center;
	margin: 0;
}

.quiz-link figure img {
	width: 16em;
	border: 2px solid white;
	border-radius: 3px;
	transition: 100ms;
}

.quiz-link figure img:hover {
	opacity: 0.7;
}

.quiz-link figcaption {
	color: #005aba;
	font-size: 85%;
	font-weight: bold;
	text-decoration: underline;
}

.quiz-link p {
	display: grid;
	justify-items: center;
	margin: 0;
	font-size: 70%;
}


@media (max-width: 640px) {

	.quiz-link ul {
		grid-gap: 1em;
	}

}


@media (min-width: 641px) {

	.quiz-link ul {
		grid-template-columns: repeat(2, 1fr);
		grid-gap: 1.5em;
		align-items: start;
	}

}


.top p {
	display: flex;
	align-items: center;
	justify-content: center;
}


@media (max-width: 640px) {
	.top p {
		flex-wrap: wrap;
		height: 4em;
	}
	.top p img[src*="text"] {
		margin: 0 1em;
	}
	.top p img[src*="chara"] {
		font-size: 85%;
	}
	.top p img[src*="chara1"] {
		margin-right: auto;
	}
	.top p img[src*="chara2"] {
		margin-left: auto;
	}
}

@media (min-width: 641px) {
	.top p img[src*="text"] {
		transform: translateY(2em);
	}
	.top p img[src*="chara1"] {
		order: 1;
	}
	.top p img[src*="text"] {
		order: 2;
	}
	.top p img[src*="chara2"] {
		order: 3;
	}
}


.wq-view {
	position: relative;
}


.worldQuiz {
	display: flex;
	flex-direction: column;
	align-items: center;
	margin: 0.5em 0;
	padding: 1px 1em 4em;
	background: #82ddff url(../images/common/back.png) no-repeat center bottom / 100% auto;
}

body.world-quiz-finished .worldQuiz.flag {
	padding-bottom: 2em;
}

.worldQuiz h1 {
	margin: 1em 0;
	font-size: inherit;
	text-align: center;
}
.worldQuiz.index h1 {
	margin: 1.5em 0;
}

.worldQuiz button {
	border: none;
	margin: 0;
	padding: 0;
	background: none;
	font-size: inherit;
	cursor: pointer;
}


@media (max-width: 640px) {
	.worldQuiz {
		font-size: 4vw;
	}
}


@media (min-width: 641px) {
	.worldQuiz,
	.worldQuiz img {
		font-size: 20px;
	}
}