/* ==========================================================
 * 動画で見るシン・トセイ（動画一覧）
 * ブレークポイントはテーマに合わせる（980px以上3列／540px以上2列／それ未満1列）
 * ========================================================== */

/* 本文の幅をヘッダーと揃える（テーマ既定の 720px ではサムネイルが小さくなるため） */
@media screen and (min-width: 782px) {
	.post-type-archive-movie .site-content {
		max-width: 1120px;
	}
}

/* 見出しまわり（いいね・パンくず・リード文）：本文の他ページと同じ 720px 幅で中央寄せ */
.movie-intro {
	max-width: 720px;
	margin: 0 auto 40px;
}
.movie-intro .wpulike {
	margin-bottom: 8px;
}
.movie-breadcrumb {
	margin-bottom: 24px;
}
.movie-lead {
	padding: 20px 30px;
	border-top: 2px solid #111;
	border-bottom: 2px solid #111;
}
.movie-lead p:last-child {
	margin-bottom: 0;
}
@media screen and (max-width: 539px) {
	.movie-lead {
		padding: 16px 10px;
	}
}

.movie-grid {
	list-style: none;
	margin: 0 -15px;
	padding: 0;
	display: grid;
	grid-template-columns: 1fr;
}
@media screen and (min-width: 540px) {
	.movie-grid { grid-template-columns: repeat(2, 1fr); }
}
@media screen and (min-width: 980px) {
	.movie-grid { grid-template-columns: repeat(3, 1fr); }
}

.movie-item {
	margin: 0;
	padding: 0 15px 40px;
}

.movie-card {
	display: block;
	width: 100%;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: none;
	box-shadow: none;
	text-align: left;
	font: inherit;
	color: inherit;
	letter-spacing: inherit;
	text-transform: none;
	cursor: pointer;
}
.movie-card:hover,
.movie-card:focus {
	background: none;
	color: inherit;
}
.movie-card:focus-visible {
	outline: 3px solid #0000ff;
	outline-offset: 4px;
}

/* サムネイル（16:9） */
.movie-thumb {
	position: relative;
	display: block;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: #f4f5f6;
	margin-bottom: 12px;
}
.movie-thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* 再生ボタン */
.movie-play {
	position: absolute;
	right: 10px;
	bottom: 10px;
	width: 48px;
	height: 34px;
	border-radius: 8px;
	background: rgba(0, 0, 0, .75);
}
.movie-play::after {
	content: "";
	position: absolute;
	left: 19px;
	top: 9px;
	border-style: solid;
	border-width: 8px 0 8px 13px;
	border-color: transparent transparent transparent #fff;
}
.movie-card:hover .movie-play { background: #c00; }

/* タイトル */
.movie-title {
	display: block;
	font-size: 19px;
	font-weight: 700;
	line-height: 1.5;
	color: #111;
}
.movie-card:hover .movie-title {
	color: #0000ff;
	text-decoration: underline;
}

/* 登録日：TOPページの記事一覧（.post-grid .entry-meta）と同じ見た目 */
.movie-date {
	display: block;
	margin-top: 1rem;
	color: #757575;
	font-size: 90%;
}
@media screen and (min-width: 540px) {
	.movie-date { font-size: 85%; }
}

/* NEW タグ：タイトルの左（既存の「Featured」ラベルと同じ見た目） */
.movie-new {
	display: inline-block;
	margin-right: 8px;
	padding: 2px 8px 1px;
	border-radius: 5px;
	background: #111;
	color: #fff;
	font-size: 12px;
	font-weight: 400;
	line-height: 1.4;
	letter-spacing: .05em;
	vertical-align: .15em;
	text-decoration: none;
}

.movie-none {
	margin-bottom: 3rem;
}

/* ページ送りの上余白 */
.post-type-archive-movie .pagination {
	margin-top: 8px;
}

/* ==========================================================
 * モーダル
 * ========================================================== */
.movie-modal {
	width: min(960px, calc(100% - 32px));
	max-width: none;
	max-height: calc(100% - 32px);
	padding: 0;
	border: 0;
	background: #000;
	color: #fff;
}
.movie-modal::backdrop {
	background: rgba(0, 0, 0, .8);
}
.movie-modal__head {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 12px;
	padding: 10px 12px 10px 16px;
	background: #111;
}
.movie-modal__title {
	margin: 0;
	color: #fff;
	font-size: 16px;
	line-height: 1.5;
}
.movie-modal__close {
	flex: none;
	padding: 6px 12px;
	border: 0;
	border-radius: 4px;
	background: #fff;
	color: #111;
	font: inherit;
	font-size: 14px;
	line-height: 1.5;
	cursor: pointer;
}
.movie-modal__close:hover,
.movie-modal__close:focus {
	background: #eee;
	color: #111;
}
.movie-modal__close:focus-visible {
	outline: 3px solid #ffd54f;
	outline-offset: 2px;
}
.movie-modal__player {
	position: relative;
	aspect-ratio: 16 / 9;
	background: #000;
}
.movie-modal__player iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

body.movie-modal-open {
	overflow: hidden;
}
