/* Misma línea visual que la tienda: Poppins, negro, café #5d4024. */
.vsm-cj {
	--vsm-brown: var(--theme-palette-color-1, #5d4024);
	--vsm-sand: var(--theme-palette-color-2, #dbccbc);
	--vsm-cream: var(--theme-palette-color-4, #f2eee5);
	display: grid;
	gap: 32px;
	margin: 32px 0 48px;
	font-family: Poppins, sans-serif;
}

@media (min-width: 900px) {
	.vsm-cj {
		grid-template-columns: 1fr 340px;
		align-items: start;
	}
}

.vsm-cj__items {
	display: grid;
	gap: 16px;
}

.vsm-cj__item {
	display: grid;
	grid-template-columns: 110px 1fr;
	gap: 16px;
	align-items: center;
	padding-bottom: 16px;
	border-bottom: 1px solid var(--vsm-sand);
}

.vsm-cj__media {
	display: block;
	aspect-ratio: 1 / 1;
	background: #fff;
}

.vsm-cj__media img {
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.vsm-cj__name {
	display: block;
	margin-bottom: 4px;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.4;
	color: #000;
	text-decoration: none;
	text-transform: uppercase;
}

.vsm-cj__name:hover {
	color: var(--vsm-brown);
}

.vsm-cj__price {
	margin-bottom: 8px;
	font-size: 16px;
	font-weight: 700;
	color: #000;
}

.vsm-cj__price ins {
	text-decoration: none;
}

.vsm-cj__field {
	margin: 4px 0 8px;
}

.vsm-cj__label {
	display: block;
	margin-bottom: 8px;
	font-size: 13px;
	font-weight: 600;
}

.vsm-cj__elegida {
	font-style: normal;
	font-weight: 400;
	opacity: 0.6;
}

.vsm-cj__elegida.is-elegida {
	font-weight: 700;
	opacity: 1;
}

.vsm-cj__sizes {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.vsm-cj__size {
	min-width: 48px;
	height: 42px;
	padding: 0 12px;
	font: inherit;
	font-size: 14px;
	font-weight: 600;
	color: #000;
	background: #fff;
	border: 1px solid #ccc;
	border-radius: 6px;
	cursor: pointer;
	transition: border-color 0.15s, background 0.15s, color 0.15s;
}

.vsm-cj__size:hover:not(:disabled) {
	border-color: var(--vsm-brown);
}

.vsm-cj__size[aria-checked="true"] {
	color: #fff;
	background: var(--vsm-brown);
	border-color: var(--vsm-brown);
}

.vsm-cj__size:disabled {
	opacity: 0.35;
	text-decoration: line-through;
	cursor: not-allowed;
}

.vsm-cj__size:focus-visible {
	outline: 2px solid var(--vsm-brown);
	outline-offset: 2px;
}

.vsm-cj__agotado {
	margin: 0;
	font-weight: 600;
	color: #b3261e;
}

.vsm-cj__resumen {
	position: sticky;
	top: 100px;
	padding: 24px;
	background: var(--vsm-cream);
	border-radius: 8px;
}

/* Tex: sentado sobre el recuadro del precio, con globo de texto. */
.vsm-cj__resumen.has-tex {
	margin-top: 125px;
}

@media (min-width: 900px) {
	.vsm-cj__resumen.has-tex {
		top: 220px;
	}
}

.vsm-cj__tex {
	position: absolute;
	right: 16px;
	bottom: calc(100% - 18px);
	width: 130px;
	pointer-events: none;
	animation: vsm-tex-entra 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

.vsm-cj__tex-img {
	display: block;
	width: 100%;
	height: auto;
	transform-origin: 50% 100%;
	animation: vsm-tex-mece 3.2s ease-in-out 0.9s infinite;
}

.vsm-cj__globo {
	position: absolute;
	right: calc(100% - 4px);
	top: 18px;
	width: max-content;
	max-width: 180px;
	padding: 8px 12px;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.3;
	color: #000;
	background: #fff;
	border: 2px solid var(--vsm-brown);
	border-radius: 14px;
	box-shadow: 0 3px 0 var(--vsm-sand);
}

.vsm-cj__globo::after {
	content: "";
	position: absolute;
	right: -9px;
	top: 14px;
	border: 8px solid transparent;
	border-left-color: var(--vsm-brown);
	border-right: 0;
}

.vsm-cj__globo.is-pop {
	animation: vsm-globo-pop 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Tex brinca de gusto cuando aparece el ahorro. */
.vsm-cj__tex.is-festeja .vsm-cj__tex-img {
	animation: vsm-tex-brinca 0.7s cubic-bezier(0.34, 1.56, 0.64, 1), vsm-tex-mece 3.2s ease-in-out 0.7s infinite;
}

@keyframes vsm-tex-brinca {
	0% { transform: translateY(0) scale(1, 1); }
	20% { transform: translateY(0) scale(1.08, 0.9); }
	50% { transform: translateY(-26px) scale(0.95, 1.06) rotate(-6deg); }
	80% { transform: translateY(0) scale(1.06, 0.94); }
	100% { transform: translateY(0) scale(1, 1); }
}

@keyframes vsm-tex-entra {
	0% { opacity: 0; transform: translateY(40px) scale(0.6); }
	60% { opacity: 1; transform: translateY(-10px) scale(1.05); }
	100% { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes vsm-tex-mece {
	0%, 100% { transform: rotate(-3deg); }
	50% { transform: rotate(3deg); }
}

@keyframes vsm-globo-pop {
	0% { transform: scale(0.75); }
	70% { transform: scale(1.08); }
	100% { transform: scale(1); }
}

@media (prefers-reduced-motion: reduce) {
	.vsm-cj__tex,
	.vsm-cj__tex-img,
	.vsm-cj__tex.is-festeja .vsm-cj__tex-img,
	.vsm-cj__globo.is-pop {
		animation: none;
	}
}

.vsm-cj__linea {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	margin-bottom: 8px;
	font-size: 15px;
}

.vsm-cj__linea[hidden] {
	display: none;
}

.vsm-cj__linea del {
	opacity: 0.6;
}

.vsm-cj__linea--total {
	font-size: 18px;
}

.vsm-cj__linea--total strong {
	font-size: 24px;
	color: #000;
}

.vsm-cj__ahorro {
	margin: 4px 0 16px;
	font-weight: 700;
	color: #2f5a27;
}

.vsm-cj__ahorro[hidden] {
	display: none;
}

.vsm-cj__btn {
	display: block;
	width: 100%;
	padding: 14px 16px;
	font: inherit;
	font-size: 15px;
	font-weight: 700;
	color: #fff;
	background: var(--vsm-brown);
	border: 0;
	border-radius: 6px;
	cursor: pointer;
}

.vsm-cj__btn:hover:not(:disabled) {
	filter: brightness(1.15);
}

.vsm-cj__btn:disabled {
	opacity: 0.55;
	cursor: default;
}

.vsm-cj__msg {
	margin: 10px 0 0;
	font-size: 14px;
	color: #b3261e;
}

.vsm-cj__msg:empty {
	display: none;
}

.vsm-cj__nota {
	margin: 12px 0 0;
	font-size: 12px;
	opacity: 0.75;
}

/* La página del conjunto no muestra autor ni fecha. */
.single-vsm_conjunto .entry-meta {
	display: none;
}

/* "Te has ahorrado $X" en el carrito */
.vsm-cj-ahorro-carrito {
	margin: 0 0 20px;
	padding: 14px 18px;
	font-size: 16px;
	color: #2f5a27;
	background: #e6f1e3;
	border-radius: 8px;
}

.vsm-cj-ahorro-carrito[hidden] {
	display: none;
}

.vsm-cj-ahorro-total th,
.vsm-cj-ahorro-total td {
	color: #2f5a27;
}

/* Aviso en la página de producto */
.vsm-cj-aviso {
	margin: 16px 0;
	padding: 12px 16px;
	font-size: 14px;
	line-height: 1.5;
	background: var(--theme-palette-color-4, #f2eee5);
	border-left: 3px solid var(--theme-palette-color-1, #5d4024);
	border-radius: 4px;
}

.vsm-cj-aviso a {
	font-weight: 600;
	color: var(--theme-palette-color-1, #5d4024);
}

.vsm-cj-aviso__link {
	white-space: nowrap;
}
