/**
 * Video Comments — card icon + comment panel
 */

/* -------------------- Comment icon on the video card --------------------
 * Fully self-contained: does NOT extend .iv-iconbtn, whose rules live only in
 * the inline <style> blocks of single-blog.php and template-videofeed.php.
 * Matches their 36px white circle so it sits flush with Save and Share.
 */
.mll-vc-btn {
	position: relative;
	display: grid;
	place-items: center;
	width: 36px;
	height: 36px;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: #fff;
	color: #304e63;
	cursor: pointer;
	transition: background .15s, color .15s;
}

.mll-vc-btn:hover {
	background: #f2f5f7;
}

.mll-vc-btn:focus {
	outline: 0;
}

.mll-vc-btn.is-active {
	background: #304e63;
	color: #fff;
}

.mll-vc-badge {
	position: absolute;
	top: -3px;
	right: -3px;
	min-width: 17px;
	height: 17px;
	padding: 0 4px;
	border-radius: 9px;
	background: #9b1c2e;
	color: #fff;
	font-size: 10px;
	font-weight: 700;
	line-height: 17px;
	text-align: center;
	pointer-events: none;
}

/* -------------------- The in-card panel --------------------
 * Anchored to the bottom of the video card it was opened from. Not a popup —
 * no backdrop, no page lock, the card stays exactly where it is.
 */
.mll-vc-panel {
	position: absolute;
	left: 8px;
	right: 8px;
	bottom: 8px;
	z-index: 6;
	display: flex;
	flex-direction: column;
	max-height: 66%;
	padding: 14px 14px 12px;
	background: #fff;
	border-radius: 10px;
	box-shadow: 0 -4px 22px rgba(0, 0, 0, .18);
	text-align: left;
}

.mll-vc-panel[hidden] {
	display: none !important;
}

/* Every host must be a positioning context for the panel above:
 * .iv-card / .iv-reel  — the grid and reels cards
 * .swiper-slide        — the #video-popup slider built by vendor.js
 * .iv-modal__box       — the #iv-modal player built by developer.js
 */
.iv-card,
.iv-reel,
#video-popup .swiper-slide,
.iv-modal__box {
	position: relative;
}

/* The slider stacks its own arrows and controls fairly high. */
#video-popup .swiper-slide .mll-vc-panel,
.iv-modal__box .mll-vc-panel {
	z-index: 120;
}

/* -------------------- Comment list -------------------- */
.mll-vc-list {
	flex: 1 1 auto;
	overflow-y: auto;
	min-height: 60px;
	margin-bottom: 12px;
	padding-right: 10px;
}

.mll-vc-list::-webkit-scrollbar {
	width: 4px;
}

.mll-vc-list::-webkit-scrollbar-track {
	background: #f0f2f4;
	border-radius: 3px;
}

.mll-vc-list::-webkit-scrollbar-thumb {
	background: #9b1c2e;
	border-radius: 3px;
}

.mll-vc-item {
	padding-bottom: 12px;
	margin-bottom: 12px;
	border-bottom: 1px solid #eef1f3;
}

.mll-vc-item:last-child {
	border-bottom: 0;
	margin-bottom: 0;
	padding-bottom: 0;
}

.mll-vc-head {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 5px;
}

.mll-vc-avatar {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: #eaeef1;
	flex: 0 0 20px;
}

.mll-vc-avatar svg {
	fill: #7a8b96;
	width: 13px;
	height: 13px;
}

.mll-vc-name {
	font-size: 13px;
	font-weight: 700;
	color: #21445c;
}

.mll-vc-date {
	margin-left: auto;
	font-size: 11px;
	color: #8b9aa4;
	white-space: nowrap;
}

.mll-vc-text {
	margin: 0;
	font-size: 13px;
	line-height: 1.5;
	color: #4a5b66;
}

.mll-vc-empty {
	margin: 0;
	font-size: 13px;
	color: #8b9aa4;
	font-style: italic;
}

/* -------------------- Form -------------------- */
.mll-vc-form {
	flex: 0 0 auto;
}

.mll-vc-form .mll-vc-input-name,
.mll-vc-form .mll-vc-input-text {
	width: 100%;
	border: 1px solid #e3e7ea;
	border-radius: 5px;
	background: #f7f9fa;
	padding: 9px 12px;
	font-size: 13px;
	color: #21445c;
	margin-bottom: 9px;
	transition: border-color .2s, background .2s;
}

.mll-vc-form .mll-vc-input-name::placeholder,
.mll-vc-form .mll-vc-input-text::placeholder {
	color: #97a4ac;
}

.mll-vc-form .mll-vc-input-name:focus,
.mll-vc-form .mll-vc-input-text:focus {
	outline: 0;
	background: #fff;
	border-color: #c3ccd2;
}

.mll-vc-form .mll-vc-input-text {
	min-height: 62px;
	resize: vertical;
}

.mll-vc-recaptcha {
	margin-bottom: 9px;
	transform: scale(.82);
	transform-origin: 0 0;
	height: 62px;
}

.mll-vc-submit {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	border: 0;
	border-radius: 5px;
	background: #21445c;
	color: #fff;
	font-size: 14px;
	font-weight: 600;
	padding: 11px 16px;
	cursor: pointer;
	transition: background .2s, opacity .2s;
}

.mll-vc-submit:hover {
	background: #1a3547;
}

.mll-vc-submit:focus {
	outline: 0;
}

.mll-vc-submit[disabled],
.mll-vc-submit.is-loading {
	opacity: .6;
	cursor: not-allowed;
}

.mll-vc-msg {
	display: none;
	margin: 0 0 9px;
	font-size: 13px;
	line-height: 1.4;
}

.mll-vc-msg.success {
	color: #1c6b32;
}

.mll-vc-msg.error {
	color: #b32d2e;
}

/* -------------------- Responsive -------------------- */
@media (max-width: 767px) {
	.mll-vc-panel {
		max-height: 76%;
		left: 6px;
		right: 6px;
		bottom: 6px;
		padding: 12px 12px 10px;
	}

	.mll-vc-list {
		margin-bottom: 10px;
	}

	.mll-vc-recaptcha {
		transform: scale(.74);
		height: 56px;
	}
}
