@charset "UTF-8";

/* -----------------------------
   モーダル全体の基本設定
----------------------------- */
.movie-dialog {
	position: fixed;
	inset: 0;
	display: flex;
	justify-content: center;
	align-items: center;
	visibility: hidden;
	opacity: 0;
	transition: opacity 0.4s ease, visibility 0.4s ease;
	z-index: 1000;
}

/* モーダルを表示 */
.movie-dialog.is-show {
	visibility: visible;
	opacity: 1;
}

/* 背景の半透明黒 */
.movie-dialog-background {
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.8);
	visibility: hidden;
	opacity: 0;
	transition: opacity 0.4s ease, visibility 0.4s ease;
	z-index: 999;
}

/* 背景を表示 */
.movie-dialog-background.is-show {
	visibility: visible;
	opacity: 1;
}

/* -----------------------------
   プレイヤーコンテナ
----------------------------- */
.movie-container {
	position: relative;
	max-width: 80%;
	width: 50vw;
	aspect-ratio: 16 / 9;
	background: #000;
	border-radius: 8px;
	overflow: hidden;
	z-index: 1001;
	box-shadow: 0 0 20px rgba(0, 0, 0, 0.6);
}

/* YouTube iframeコンテナ */
.movie-iframe-container iframe {
	width: 100%;
	height: 100%;
	border: none;
}

/* -----------------------------
   閉じるボタン（×）
----------------------------- */
.movie-dialog-close {
	position: absolute;
	top: 20px;
	right: 25px;
	font-size: 28px;
	color: #fff;
	cursor: pointer;
	z-index: 1002;
	transition: transform 0.3s ease, opacity 0.3s ease;
}

.movie-dialog-close::before {
	content: "✕";
}

.movie-dialog-close:hover {
	transform: scale(1.2);
	opacity: 0.8;
}

/* -----------------------------
   サムネイルボタン
----------------------------- */
.movie__container .movie__wrap .movie__itemWrap .movie-list {
	width: auto;
	aspect-ratio: 16/9;
}
.movie-trigger {
	display: inline-block;
	position: relative;
	cursor: pointer;
	border: none;
	background: none;
	padding: 0;
	transition: transform 0.3s ease, opacity 0.3s ease;
	height: 100%;
	aspect-ratio: 16/9;
	width: 100%;
}

.movie-trigger img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 16/9;
	object-fit: cover;
	border-radius: 8px 8px 0 0;
	height: 100%;
	position: relative;
}

/* 再生アイコンを重ねる */
.movie-trigger::after {
	content: "▶";
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	font-size: 48px;
	color: rgba(255, 255, 255, 0.9);
	text-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
	pointer-events: none;
	opacity: 0.9;
}

/* ホバー */
.movie-trigger:hover {
	opacity: 0.9;
}

/* -----------------------------
   レスポンシブ対応
----------------------------- */
@media (max-width: 768px) {
	.movie-container {
		max-width: 98%;
		width: 98%;
	}

	.movie-dialog-close {
		top: 10px;
		right: 15px;
		font-size: 24px;
	}
}
