/* STM YouTube — วิดีโอ + บทบรรยาย (transcript) ในหน้าบทความ
   ไฟล์นี้แยกจาก CSS อื่น แก้สีได้ที่ตัวแปรด้านล่าง */
.stm-yt-list {
	--yt-panel-bg: #FAF6EE;
	--yt-panel-line: #EBE1CF;
	--yt-title: #2B2620;
	--yt-text: #5A5247;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
	gap: 28px 20px;
	align-items: start;
	margin: 24px 0;
}
.stm-yt {
	margin: 0;
	min-width: 0;
}

/* กรอบวิดีโอ 16:9 */
.stm-yt-frame {
	position: relative;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	border-radius: 10px;
	background: #000;
}
.stm-yt.is-short .stm-yt-frame {
	aspect-ratio: 9 / 16;
	max-width: 320px;
}
.stm-yt iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}
.stm-yt-cap {
	margin-top: 8px;
	font-size: .9em;
}

/* บทบรรยายวิดีโอ */
.stm-yt-tr {
	margin-top: 14px;
	padding: 20px 22px;
	border: 1px solid var(--yt-panel-line);
	border-radius: 10px;
	background: var(--yt-panel-bg);
}
.stm-yt-tr summary {
	display: block;
	cursor: pointer;
	list-style: none;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.5;
	color: var(--yt-title);
}
.stm-yt-tr summary::-webkit-details-marker {
	display: none;
}
.stm-yt-tr summary::after {
	content: "\25BE";
	margin-left: 6px;
	font-size: 11px;
	font-weight: 400;
	opacity: .7;
}
.stm-yt-tr[open] summary::after {
	content: "\25B4";
}
.stm-yt-tr-body {
	margin-top: 16px;
}
.stm-yt-tr-body p {
	margin: 0 0 16px;
	font-size: 14px;
	line-height: 1.9;
	color: var(--yt-text);
}
.stm-yt-tr-body p:last-child {
	margin-bottom: 0;
}
