/* Shoppable Video Carousel */

.svc {
	--svc-bg: #fdf3df; --svc-title: #1a1a1a; --svc-card-bg: #fff; --svc-text: #1a1a1a; --svc-price: #1a1a1a;
	--svc-btn-bg: #8a1538; --svc-btn-text: #fff; --svc-btn-radius: 10px;
	--svc-arrow-bg: #fff; --svc-arrow-color: #111;
	--svc-gap: 20px; --svc-radius: 24px; --svc-ratio: 3/4;
	--svc-cols-d: 4; --svc-cols-t: 3; --svc-cols-m: 1.4;
	--svc-max: 1400px; --svc-pad-y: 48px; --svc-title-size: 40px; --svc-align: center; --svc-transform: uppercase;
	--svc-n: var(--svc-cols-m);
	box-sizing: border-box;
	position: relative;
	width: 100%;
	padding: var(--svc-pad-y) 0;
	background: var(--svc-bg);
	color: var(--svc-text);
	font: inherit;
	line-height: 1.4;
}
@media (min-width: 640px)  { .svc { --svc-n: var(--svc-cols-t); } }
@media (min-width: 1024px) { .svc { --svc-n: var(--svc-cols-d); } }

.svc *, .svc *::before, .svc *::after { box-sizing: border-box; }
.svc__inner { max-width: var(--svc-max); margin: 0 auto; padding: 0 clamp(16px, 3vw, 32px); }

.svc__head { margin-bottom: clamp(20px, 3vw, 36px); text-align: var(--svc-align); }
.svc__title { margin: 0; color: var(--svc-title); font-size: var(--svc-title-size); line-height: 1.1; font-weight: 700; }
.svc__sub { margin: 0.5em 0 0; color: var(--svc-title); opacity: 0.75; }

.svc__viewport { position: relative; }

/* Track */
.svc__track {
	display: flex;
	gap: var(--svc-gap);
	padding: 4px 2px 14px;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	overscroll-behavior-x: contain;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
}
.svc__track::-webkit-scrollbar { display: none; }

/* Card */
.svc-card {
	flex: 0 0 calc((100% - (var(--svc-n) - 1) * var(--svc-gap)) / var(--svc-n));
	min-width: 0;
	display: flex;
	flex-direction: column;
	background: var(--svc-card-bg);
	border-radius: var(--svc-radius);
	overflow: hidden;
	box-shadow: 0 2px 14px rgba(0, 0, 0, 0.07);
	scroll-snap-align: start;
}

.svc-card__video {
	position: relative;
	display: block;
	width: 100%;
	margin: 0; padding: 0; border: 0;
	aspect-ratio: var(--svc-ratio);
	background: #2a2323;
	color: #fff;
	overflow: hidden;
	cursor: pointer;
}
.svc-card__video:focus-visible { outline: 3px solid var(--svc-btn-bg); outline-offset: -3px; }
.svc-card__video video {
	position: absolute; inset: 0;
	width: 100%; height: 100%;
	object-fit: cover;
	pointer-events: none;
}
.svc-card__play {
	position: absolute; left: 50%; top: 50%;
	display: grid; place-items: center;
	width: 56px; height: 56px;
	margin: -28px 0 0 -28px;
	border-radius: 50%;
	background: rgba(0, 0, 0, 0.38);
	backdrop-filter: blur(4px);
	transition: opacity 0.2s, transform 0.2s;
}
.svc-card__video:hover .svc-card__play { transform: scale(1.08); }
.svc-card.is-playing .svc-card__play { opacity: 0; }
.svc-card__caption {
	position: absolute; left: 14px; right: 14px; bottom: 18px;
	text-align: center;
	font-weight: 600; font-size: 1.02rem; line-height: 1.3;
	text-shadow: 0 1px 6px rgba(0, 0, 0, 0.7);
	pointer-events: none;
}

.svc-card__body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 14px; }
.svc-card__product { display: flex; align-items: center; gap: 12px; min-width: 0; }
.svc-card__thumb { flex: none; width: 52px; height: 52px; border-radius: 10px; object-fit: cover; background: rgba(127, 127, 127, 0.15); }
.svc-card__info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.svc-card__title {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: var(--svc-title-lines, 1);
	line-clamp: var(--svc-title-lines, 1);
	overflow: hidden;
	overflow-wrap: anywhere;
	color: var(--svc-text);
	font-weight: 600;
	line-height: 1.3;
	letter-spacing: 0.01em;
}
.svc-card__price { color: var(--svc-price); font-size: 0.92rem; font-weight: 600; }
.svc-card__price s, .svc-card__price del { margin: 0 0.4em 0 0; font-weight: 400; opacity: 0.55; text-decoration: line-through; }
.svc-card__price ins { text-decoration: none; background: none; }
.svc-card__price .screen-reader-text, .svc-modal .screen-reader-text {
	position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0;
	overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.svc-card__ext {
	flex: none;
	display: grid; place-items: center;
	width: 34px; height: 34px;
	border-radius: 50%;
	background: rgba(127, 127, 127, 0.14);
	color: var(--svc-text);
	transition: background 0.15s;
}
.svc-card__ext:hover { background: rgba(127, 127, 127, 0.28); }

.svc-card__btn {
	display: block;
	padding: 0.95em 1em;
	border-radius: var(--svc-btn-radius);
	background: var(--svc-btn-bg);
	color: var(--svc-btn-text);
	text-align: center; text-decoration: none;
	font-weight: 700; letter-spacing: 0.03em; line-height: 1.2;
	text-transform: var(--svc-transform);
	transition: filter 0.15s, transform 0.1s;
}
.svc-card__btn:hover { filter: brightness(1.12); color: var(--svc-btn-text); }
.svc-card__btn:active { transform: translateY(1px); }
.svc-card__btn:focus-visible, .svc-card__ext:focus-visible { outline: 2px solid var(--svc-btn-bg); outline-offset: 2px; }

/* Arrows */
.svc__arrow {
	position: absolute; top: 38%; z-index: 3;
	display: grid; place-items: center;
	width: 44px; height: 44px; padding: 0;
	border: 0; border-radius: 50%;
	background: var(--svc-arrow-bg);
	color: var(--svc-arrow-color);
	box-shadow: 0 2px 12px rgba(0, 0, 0, 0.22);
	cursor: pointer;
	transform: translateY(-50%);
	transition: opacity 0.2s, transform 0.15s;
}
.svc__arrow:hover { transform: translateY(-50%) scale(1.07); }
.svc__arrow:focus-visible { outline: 2px solid var(--svc-btn-bg); outline-offset: 2px; }
.svc__arrow[disabled] { opacity: 0; pointer-events: none; }
.svc__arrow--prev { left: 10px; }
.svc__arrow--next { right: 10px; }
@media (max-width: 639px) { .svc__arrow { display: none; } }

/* ---------- Player modal ---------- */

html.svc-lock { overflow: hidden; }
.svc-modal {
	position: fixed; inset: 0; z-index: 100000;
	display: flex; align-items: center; justify-content: center; gap: 24px;
	padding: 16px;
	background: rgba(20, 12, 12, 0.8);
	backdrop-filter: blur(3px);
}
.svc-modal[hidden], .svc-modal [hidden] { display: none !important; }
.svc-modal button { font: inherit; }

.svc-modal__player {
	position: relative;
	height: min(88vh, 780px);
	aspect-ratio: 9 / 16;
	max-width: 100%;
	border-radius: 22px;
	overflow: hidden;
	background: #000;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}
.svc-modal__player video { width: 100%; height: 100%; object-fit: cover; display: block; cursor: pointer; }
.svc-modal__progress { position: absolute; top: 0; left: 0; right: 0; height: 3px; background: rgba(255, 255, 255, 0.28); z-index: 2; }
.svc-modal__progress span { display: block; height: 100%; width: 0; background: #fff; }

.svc-modal__tools { position: absolute; top: 14px; right: 14px; display: flex; gap: 8px; z-index: 2; }
.svc-modal__tools button, .svc-modal__tools a {
	display: grid; place-items: center;
	width: 38px; height: 38px; padding: 0;
	border: 0; border-radius: 50%;
	background: rgba(0, 0, 0, 0.5);
	color: #fff; cursor: pointer; text-decoration: none;
}
.svc-modal__tools button:hover, .svc-modal__tools a:hover { background: rgba(0, 0, 0, 0.75); color: #fff; }
.svc-modal__tools .svc-modal__wa { background: #25d366; }
.svc-modal__tools .svc-modal__wa:hover { background: #1fb457; }

.svc-modal__close {
	position: fixed; top: 20px; right: 20px; z-index: 3;
	display: grid; place-items: center;
	width: 44px; height: 44px; padding: 0;
	border: 0; border-radius: 50%;
	background: rgba(255, 255, 255, 0.92); color: #111; cursor: pointer;
}
.svc-modal__nav {
	flex: none;
	display: grid; place-items: center;
	width: 52px; height: 52px; padding: 0;
	border: 0; border-radius: 50%;
	background: #fff; color: #111;
	box-shadow: 0 2px 14px rgba(0, 0, 0, 0.3);
	cursor: pointer;
}
.svc-modal__nav:hover { transform: scale(1.06); }
.svc-modal button:focus-visible, .svc-modal a:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }

.svc-modal__bar {
	position: absolute; left: 8px; right: 8px; bottom: 8px; z-index: 2;
	display: flex; align-items: center; gap: 12px;
	padding: 10px;
	border-radius: 18px;
	background: #fff; color: var(--svc-text, #1a1a1a);
}
.svc-modal__bar .svc-card__thumb { width: 44px; height: 44px; border-radius: 8px; }
.svc-modal__bar .svc-card__info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.svc-modal__bar .svc-card__title { font-weight: 600; font-size: 0.95rem; color: var(--svc-text, #1a1a1a); }
.svc-modal__bar .svc-card__price { font-size: 0.85rem; font-weight: 600; color: var(--svc-price, #1a1a1a); }
.svc-modal__bar .svc-card__price s, .svc-modal__bar .svc-card__price del { margin: 0 0.4em 0 0; font-weight: 400; opacity: 0.55; text-decoration: line-through; }
.svc-modal__bar .svc-card__price ins { text-decoration: none; background: none; }
.svc-modal__cta {
	flex: none;
	padding: 0.75em 1.3em;
	border-radius: 999px;
	background: var(--svc-btn-bg, #8a1538); color: var(--svc-btn-text, #fff);
	text-decoration: none; font-weight: 700; font-size: 0.9rem; line-height: 1.1; white-space: nowrap;
	text-transform: var(--svc-transform, none);
}
.svc-modal__toast {
	position: absolute; left: 50%; top: 60px; z-index: 3;
	padding: 0.45em 1em; border-radius: 999px;
	background: rgba(0, 0, 0, 0.75); color: #fff; font-size: 0.85rem;
	opacity: 0; transform: translate(-50%, -6px); transition: opacity 0.2s, transform 0.2s; pointer-events: none;
}
.svc-modal__toast.is-on { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 700px) {
	.svc-modal { padding: 0; gap: 0; }
	.svc-modal__player { height: 100%; width: 100%; aspect-ratio: auto; border-radius: 0; }
	.svc-modal__nav { position: fixed; top: 45%; width: 42px; height: 42px; background: rgba(255, 255, 255, 0.85); z-index: 3; }
	.svc-modal__nav--prev { left: 8px; }
	.svc-modal__nav--next { right: 8px; }
	.svc-modal__close { top: 12px; right: auto; left: 12px; width: 38px; height: 38px; }
	.svc-modal__tools { top: 12px; }
	.svc-modal__bar { bottom: calc(10px + env(safe-area-inset-bottom, 0px)); }
}

@media (prefers-reduced-motion: reduce) {
	.svc *, .svc-modal * { transition: none !important; }
}
