.ctsys-licencias,
.ctsys-historial-pedido,
.ctsys-facturacion,
.ctsys-informacion-pedido__resumen > section,
.ctsys-informacion-pedido__productos,
.ctsys-pedido-pie {
	overflow: hidden;
	border: 1px solid var(--ct-borde);
	border-radius: 0.75rem;
	background: var(--ct-superficie);
	box-shadow: var(--ct-sombra);
}

.ctsys-licencias,
.ctsys-historial-pedido {
	padding: 1.5rem;
}


body.woocommerce-view-order .woocommerce-MyAccount-content > .woocommerce-notice {
	display: none;
}


body.woocommerce-view-order .woocommerce-order-details__title,
body.woocommerce-view-order .woocommerce-table--order-details {
	display: none;
}


body.woocommerce-view-order .woocommerce-MyAccount-content > .woocommerce-customer-details {
	display: none !important;
}


body.woocommerce-view-order .order-again {
	display: none !important;
}


body.woocommerce-view-order .woocommerce-MyAccount-content > .woocommerce-notices-wrapper ~ p,
body.woocommerce-view-order h2:has(+ .woocommerce-OrderUpdates),
body.woocommerce-view-order .woocommerce-OrderUpdates {
	display: none;
}


body.woocommerce-view-order .woocommerce-MyAccount-content {
	display: grid;
	grid-template-columns: minmax( 0, 1fr );
	grid-template-areas:
		"licencias"
		"facturacion"
		"resumen"
		"productos"
		"historial"
		"acciones";
	gap: var(--ct-separacion-detalle);
	align-items: start;
}

body.woocommerce-view-order .woocommerce-MyAccount-content:has(.ctsys-guias-pedido) {
	grid-template-areas: "licencias" "guias" "facturacion" "resumen" "productos" "historial" "acciones";
}

/* WooCommerce anida estos bloques en wrappers que no aportan presentación.
 * Se convierten en transparentes para que las áreas de la vista puedan
 * mantener el ancho y el ritmo de las tarjetas sin cambiar el contenido. */
body.woocommerce-view-order .woocommerce-order-details,
body.woocommerce-view-order .ctsys-informacion-pedido {
	display: contents;
}

body.woocommerce-view-order .ctsys-licencias {
	grid-area: licencias;
}

body.woocommerce-view-order .ctsys-guias-pedido {
	grid-area: guias;
	min-width: 0;
	padding: 20px;
	border: 1px solid var(--ct-borde);
	border-radius: 16px;
	background: var(--ct-superficie);
}

body.woocommerce-view-order .ctsys-guias-pedido > h2 {
	margin: 0 0 16px;
	color: var(--ct-tinta);
	font-size: 1.125rem;
	line-height: 1.3;
}

body.woocommerce-view-order .ctsys-guia-pedido {
	min-width: 0;
	padding-top: 12px;
	border-top: 1px solid var(--ct-borde);
	color: var(--ct-tinta-suave);
	line-height: 1.6;
	overflow-wrap: anywhere;
}

body.woocommerce-view-order .ctsys-guia-pedido + .ctsys-guia-pedido { margin-top: 16px; }
body.woocommerce-view-order .ctsys-guia-pedido h3 { margin: 0 0 8px; color: var(--ct-tinta); font-size: .95rem; line-height: 1.4; }
body.woocommerce-view-order .ctsys-guia-pedido p:last-child { margin-bottom: 0; }
body.woocommerce-view-order .ctsys-guia-pedido a { color: var(--ct-acento-azul); text-decoration: underline; text-underline-offset: 3px; }
body.woocommerce-view-order .ctsys-guia-pedido a:focus-visible { outline: 2px solid var(--ct-acento-azul); outline-offset: 2px; }

body.woocommerce-view-order .ctsys-facturacion {
	grid-area: facturacion;
	width: 100%;
}

body.woocommerce-view-order .ctsys-informacion-pedido__resumen {
	grid-area: resumen;
	min-width: 0;
}

body.woocommerce-view-order .ctsys-informacion-pedido__productos {
	grid-area: productos;
	min-width: 0;
}

body.woocommerce-view-order .ctsys-historial-pedido {
	grid-area: historial;
	margin-top: 0;
	min-width: 0;
}

body.woocommerce-view-order .ctsys-pedido-pie {
	grid-area: acciones;
}

@media (min-width: 992px) {
	body.woocommerce-view-order .woocommerce-MyAccount-content {
		grid-template-columns: repeat( 2, minmax( 0, 1fr ) );
		grid-template-areas:
			"licencias licencias"
			"facturacion historial"
			"resumen resumen"
			"productos productos"
			"acciones acciones";
	}

	body.woocommerce-view-order .woocommerce-MyAccount-content:has(.ctsys-guias-pedido) {
		grid-template-areas: "licencias licencias" "guias guias" "facturacion historial" "resumen resumen" "productos productos" "acciones acciones";
	}

	body.woocommerce-view-order .ctsys-historial-pedido__tabla-wrap {
		overflow-x: visible;
	}

	body.woocommerce-view-order .ctsys-historial-pedido table {
		min-width: 0;
		table-layout: fixed;
	}

	body.woocommerce-view-order .ctsys-historial-pedido th,
	body.woocommerce-view-order .ctsys-historial-pedido td {
		padding-inline: 0.75rem;
	}
}

html body.ctsys-cuenta.woocommerce-view-order .storex-content > #post-section.st-py-default {
	padding-top: var(--ct-separacion-menu-pagina-desktop) !important;
	padding-bottom: 0 !important;
}

/* El clearfix heredado crea dos elementos vacíos dentro del layout de cuenta;
 * en una cuadrícula agregan una fila y desplazan el título sin aportar contenido. */
html body.ctsys-cuenta.woocommerce-view-order .woocommerce::before,
html body.ctsys-cuenta.woocommerce-view-order .woocommerce::after {
	display: none;
}

body.woocommerce-view-order .woocommerce-customer-details {
	order: -1;
}



.ctsys-informacion-pedido {
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
}

.ctsys-informacion-pedido__resumen {
	display: grid;
	grid-template-columns: repeat( 2, minmax( 0, 1fr ) );
	gap: 1.5rem;
	align-items: stretch;
}

.ctsys-informacion-pedido__resumen > section,
.ctsys-informacion-pedido__productos {
	box-sizing: border-box;
	padding: 0 1.5rem 1.5rem;
}

.ctsys-informacion-pedido__resumen > section {
	display: flex;
	flex-direction: column;
	min-height: 100%;
}

.ctsys-informacion-pedido__resumen > section > dl {
	flex: 1 1 auto;
}

.ctsys-informacion-pedido__resumen > section + section {
	border-left: 0;
}

.ctsys-informacion-pedido__resumen h3,
.ctsys-informacion-pedido__productos h3,
body.woocommerce-view-order .woocommerce-customer-details .woocommerce-column__title {
	box-sizing: border-box;
	display: flex;
	align-items: center;
	min-height: 3.5rem;
	margin: 0 0 1.25rem;
	padding: 1rem 0 0.85rem;
	border-bottom: 1px solid var(--ct-borde-suave);
	background: transparent;
	color: var(--ct-tinta);
	font-size: 0.92rem;
	font-weight: 800;
	letter-spacing: 0.045em;
	line-height: 1.25;
	text-transform: uppercase;
}

.ctsys-informacion-pedido dl {
	margin: 0;
}

.ctsys-informacion-pedido dl > div {
	display: grid;
	grid-template-columns: 1.25rem minmax( 6rem, max-content ) minmax( 0, 1fr );
	column-gap: 0.5rem;
	align-items: center;
	min-height: 3rem;
}

.ctsys-informacion-pedido dt,
.ctsys-informacion-pedido dd {
	display: block;
	margin: 0;
}

.ctsys-informacion-pedido dl > div > svg {
	grid-column: 1;
	width: 1.15rem;
	height: 1.15rem;
	color: var(--ct-acento-azul);
}

.ctsys-informacion-pedido dt {
	grid-column: 2;
	color: var(--ct-tinta);
	font-size: 0.84rem;
	font-weight: 800;
	letter-spacing: 0.025em;
	line-height: 1.35;
	text-transform: uppercase;
}

.ctsys-informacion-pedido dt::after {
	content: ': ';
}

.ctsys-informacion-pedido dd {
	grid-column: 3;
	min-width: 0;
	color: var(--ct-tinta-suave);
	font-size: 1rem;
	line-height: 1.45;
	overflow-wrap: anywhere;
}

.ctsys-informacion-pedido__resumen .ctsys-estado {
	display: flex;
	width: fit-content;
	justify-content: flex-start;
	align-items: center;
	gap: 0.5rem;
	margin: 0;
	font-size: 1rem;
	font-weight: 800;
	line-height: 1.35;
	white-space: nowrap;
}

.ctsys-informacion-pedido__resumen .ctsys-estado::before {
	width: 0.6rem;
	height: 0.6rem;
}

.ctsys-informacion-pedido__productos {
	overflow: hidden;
	border: 1px solid var(--ct-borde);
	border-radius: 0.75rem;
	background: var(--ct-superficie);
	box-shadow: var(--ct-sombra);
}

.ctsys-informacion-pedido__tabla-wrap,
.ctsys-historial-pedido__tabla-wrap {
	overflow-x: auto;
}

.ctsys-informacion-pedido table,
.ctsys-historial-pedido table {
	width: 100%;
	min-width: 32rem;
	table-layout: auto;
	border-collapse: collapse;
}

.ctsys-informacion-pedido th,
.ctsys-historial-pedido th {
	padding: 1rem 1.25rem;
	border-bottom: 1px solid var(--ct-borde);
	color: var(--ct-tinta);
	text-align: left;
	vertical-align: middle;
	white-space: nowrap;
}

.ctsys-informacion-pedido td,
.ctsys-historial-pedido td {
	padding: 1rem 1.25rem;
	border-bottom: 1px solid var(--ct-borde);
	color: var(--ct-tinta);
	text-align: left;
	vertical-align: middle;
}

.ctsys-informacion-pedido th,
.ctsys-historial-pedido th {
	color: var(--ct-tinta-suave);
	font-size: 0.86rem;
	font-weight: 800;
	letter-spacing: 0.035em;
	text-transform: uppercase;
}

.ctsys-informacion-pedido td,
.ctsys-historial-pedido td {
	font-size: 1rem;
	line-height: 1.45;
}

.ctsys-informacion-pedido__producto {
	white-space: normal;
}

.ctsys-informacion-pedido__producto svg {
	display: inline-block;
	margin-right: 0.55rem;
	vertical-align: middle;
}

.ctsys-informacion-pedido__producto span {
	overflow-wrap: anywhere;
}

.ctsys-informacion-pedido thead th:nth-child(2),
.ctsys-informacion-pedido thead th:nth-child(3),
.ctsys-informacion-pedido thead th:nth-child(4),
.ctsys-informacion-pedido tbody td:nth-child(2),
.ctsys-informacion-pedido tbody td:nth-child(3),
.ctsys-informacion-pedido tbody td:nth-child(4) {
	min-width: 6rem;
	text-align: center;
}

.ctsys-informacion-pedido thead th:nth-child(3),
.ctsys-informacion-pedido thead th:nth-child(4),
.ctsys-informacion-pedido tbody td:nth-child(3),
.ctsys-informacion-pedido tbody td:nth-child(4) {
	text-align: right;
}

.ctsys-informacion-pedido tfoot th,
.ctsys-informacion-pedido tfoot td {
	white-space: nowrap;
}

.ctsys-informacion-pedido tbody td:nth-child(2),
.ctsys-informacion-pedido tbody td:nth-child(3),
.ctsys-informacion-pedido tbody td:nth-child(4) {
	white-space: nowrap;
}

.ctsys-informacion-pedido tfoot th {
	text-align: right;
}

.ctsys-informacion-pedido tfoot td {
	text-align: right;
}

.ctsys-informacion-pedido tbody tr:nth-child(even),
.ctsys-historial-pedido tbody tr:nth-child(even) {
	background: var(--ct-superficie-suave);
}



.ctsys-facturacion {
	box-sizing: border-box;
	padding: 0 1.5rem 1.5rem;
}

.ctsys-facturacion > h2 {
	box-sizing: border-box;
	display: flex;
	align-items: center;
	min-height: 3.5rem;
	margin: 0 0 1.25rem;
	padding: 1rem 0 0.85rem;
	border-bottom: 1px solid var(--ct-borde-suave);
	background: transparent;
	color: var(--ct-tinta);
	font-size: 0.92rem;
	font-weight: 800;
	letter-spacing: 0.045em;
	line-height: 1.3;
	text-transform: uppercase;
}

.ctsys-facturacion__fila {
	display: flex;
	gap: 0.75rem;
	align-items: center;
	min-height: 3rem;
	color: var(--ct-tinta);
	font-size: 1rem;
	line-height: 1.4;
}

.ctsys-facturacion__fila + .ctsys-facturacion__fila {
	margin-top: 0.25rem;
}

.ctsys-facturacion__fila svg {
	flex: 0 0 auto;
	width: 1.15rem;
	height: 1.15rem;
	color: var(--ct-acento-azul);
}

.ctsys-facturacion__fila span {
	min-width: 0;
	overflow-wrap: anywhere;
}

body.woocommerce-view-order .woocommerce-customer-details address {
	margin: 0;
	padding: 1.25rem 1.25rem 0.5rem;
	color: var(--ct-tinta);
	font-style: normal;
	line-height: 1.6;
}

body.woocommerce-view-order .woocommerce-customer-details .woocommerce-columns--2 {
	display: grid;
	grid-template-columns: repeat( 2, minmax( 0, 1fr ) );
}

body.woocommerce-view-order .woocommerce-customer-details .woocommerce-column--billing-address {
	border-right: 1px solid var(--ct-borde);
}

body.woocommerce-view-order .order-again {
	margin: 0;
}

body.woocommerce-view-order .order-again .button {
	display: inline-flex;
	align-items: center;
	border: 0;
	border-radius: 0.5rem;
	padding: 0.7rem 1.4rem;
	background: var(--ct-boton-principal-fondo);
	color: var(--ct-boton-principal-texto);
	font-weight: 800;
	text-decoration: none;
	text-transform: uppercase;
}

body.woocommerce-view-order .order-again .button:hover,
body.woocommerce-view-order .order-again .button:focus {
	background: var(--ct-boton-principal-hover);
}



.woocommerce-account .woocommerce-orders-table {
	width: 100%;
	border: 1px solid var(--ct-borde);
	border-collapse: separate;
	border-spacing: 0;
	border-radius: 16px;
	overflow: hidden;
	background: var(--ct-superficie);
	box-shadow: var(--ct-sombra);
}


.woocommerce-account .woocommerce-orders-table.shop_table_responsive .woocommerce-orders-table__header-ctsys-customer,
.woocommerce-account .woocommerce-orders-table.shop_table_responsive .woocommerce-orders-table__cell-ctsys-customer {
	display: none;
}


.ctsys-historial__fecha {
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: center;
	flex-wrap: nowrap;
	gap: 0.5rem;
	width: fit-content;
	margin: 0 auto;
}

.ctsys-historial__fecha time {
	white-space: nowrap;
}

.ctsys-historial__ojo {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	border-radius: 8px;
	border: 1px solid var(--ct-boton-secundario-borde);
	background: var(--ct-boton-secundario-fondo);
	color: var(--ct-boton-secundario-texto);
	transition: background 180ms ease;
}

.ctsys-historial__ojo:hover,
.ctsys-historial__ojo:focus {
	border-color: var(--ct-acento-azul);
	background: var(--ct-superficie-suave);
	color: var(--ct-tinta);
}

.ctsys-historial__factura {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	border-radius: 8px;
	border: 1px solid var(--ct-boton-secundario-borde);
	background: var(--ct-boton-secundario-fondo);
	color: var(--ct-boton-secundario-texto);
	transition: background 180ms ease;
}

.ctsys-historial__factura:hover,
.ctsys-historial__factura:focus-visible {
	border-color: var(--ct-acento-azul);
	background: var(--ct-superficie-suave);
	color: var(--ct-tinta);
}


@media (max-width: 768px) {
	.woocommerce-account .woocommerce-orders-table.shop_table_responsive {
		min-width: 0;
	}

	body.woocommerce-orders .woocommerce-MyAccount-content {
		overflow-x: auto;
		-webkit-overflow-scrolling: touch;
	}

	.ctsys-historial__fecha {
		gap: 0.2rem;
	}

	.ctsys-historial__ojo {
		width: 20px;
		height: 20px;
		border-radius: 6px;
	}

	.ctsys-historial__factura {
		width: 20px;
		height: 20px;
		border-radius: 6px;
	}

	.ctsys-historial__ojo svg,
	.ctsys-historial__factura svg {
		width: 12px;
		height: 12px;
	}
}

.woocommerce-account .woocommerce-orders-table thead th {
	padding: 16px 20px;
	border: 0;
	background: var(--ct-superficie-suave);
	color: var(--ct-acento-azul);
	font-size: 0.8rem;
	font-weight: 800;
	letter-spacing: 0.02em;
	text-align: center;
	text-transform: uppercase;
}

.woocommerce-account .woocommerce-orders-table td {
	padding: 16px 20px;
	border: 0;
	border-top: 1px solid var(--ct-borde-suave);
	text-align: center;
	vertical-align: middle;
}

.woocommerce-account .woocommerce-orders-table tbody tr:nth-child(even) {
	background: var(--ct-superficie-suave);
}

.woocommerce-account .woocommerce-orders-table .woocommerce-button.button {
	border-color: var(--ct-boton-principal-fondo) !important;
	background: var(--ct-boton-principal-fondo) !important;
	color: var(--ct-boton-principal-texto) !important;
}

.woocommerce-account .woocommerce-orders-table .woocommerce-button.button:focus,
.woocommerce-account .woocommerce-orders-table .woocommerce-button.button:hover {
	border-color: var(--ct-boton-principal-hover) !important;
	background: var(--ct-boton-principal-hover) !important;
	color: var(--ct-boton-principal-texto) !important;
}


@media (min-width: 769px) {
	.ctsys-historial__fecha {
		gap: 0.75rem;
	}
}



.ctsys-licencias__cabecera {
	margin-bottom: 1.5rem;
}

.ctsys-licencias__cabecera h2,
.ctsys-historial-pedido h2,
.ctsys-licencias__producto h3 {
	margin-top: 0;
	color: var(--ct-acento-azul);
}

.ctsys-licencias__cabecera h2,
.ctsys-historial-pedido h2 {
	position: relative;
	margin-bottom: 0.75rem;
	padding-bottom: 0.8rem;
	font-size: clamp(1.3rem, 2vw, 1.65rem);
	letter-spacing: -0.02em;
	line-height: 1.1;
}

.ctsys-licencias__cabecera h2::after,
.ctsys-historial-pedido h2::after {
	content: '';
	position: absolute;
	bottom: 0;
	left: 0;
	width: 48px;
	height: 3px;
	border-radius: var(--ct-radio-pill);
	background: var(--ct-acento-azul);
}

.ctsys-licencias__cabecera p {
	margin-bottom: 0;
	color: var(--ct-tinta-suave);
}

.ctsys-licencias__producto + .ctsys-licencias__producto {
	margin-top: 1.5rem;
}

.ctsys-licencias__producto h3 {
	margin: 0 0 0.75rem;
	font-size: 1rem;
	line-height: 1.35;
}

.ctsys-licencias__producto ul,
.ctsys-historial-pedido ol {
	margin: 0;
	padding: 0;
	list-style: none;
}

.ctsys-licencias__clave {
	display: flex;
	gap: 0.75rem;
	align-items: center;
	justify-content: space-between;
	padding: 0.75rem;
	border: 1px solid var(--ct-borde);
	border-radius: 0.5rem;
	background: var(--ct-superficie-suave);
}

.ctsys-licencias__clave + .ctsys-licencias__clave {
	margin-top: 0.75rem;
}

.ctsys-licencias__clave code {
	overflow-wrap: anywhere;
	color: var(--ct-tinta);
	font-size: 1rem;
	font-weight: 700;
}

.ctsys-licencias .ctsys-licencias__copiar.button {
	flex: 0 0 auto;
	border-color: var(--ct-boton-secundario-borde) !important;
	background: var(--ct-boton-secundario-fondo) !important;
	color: var(--ct-boton-secundario-texto) !important;
}

.ctsys-licencias .ctsys-licencias__copiar.button:focus,
.ctsys-licencias .ctsys-licencias__copiar.button:hover {
	border-color: var(--ct-acento-azul) !important;
	background: var(--ct-superficie-suave) !important;
	color: var(--ct-tinta) !important;
}


.ctsys-licencias__clave--pendiente {
	background: var(--ct-superficie);
	border-style: dashed;
}

.ctsys-licencias__hueco {
	flex: 1 1 auto;
	min-height: 1.25rem;
	border-bottom: 1px dashed var(--ct-borde-fuerte);
}



.ctsys-historial-pedido li {
	display: grid;
	gap: 0.5rem;
	padding: 1rem 0;
	border-bottom: 1px solid var(--ct-borde);
}

.ctsys-historial-pedido li:last-child {
	padding-bottom: 0;
	border-bottom: 0;
}

.ctsys-historial-pedido time {
	color: var(--ct-acento-azul);
	font-weight: 700;
}

.ctsys-historial-pedido .ctsys-estado {
	display: inline-flex;
	font-size: 1rem;
	font-weight: 700;
	line-height: 1.35;
}


/* En el detalle el estado informa por texto y punto, nunca por una pastilla de color. */
body.woocommerce-view-order .ctsys-estado {
	display: inline-flex;
	gap: 0.45rem;
	align-items: center;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	color: var(--ct-acento-azul);
}

body.woocommerce-view-order .ctsys-estado::before {
	width: 0.45rem;
	height: 0.45rem;
	flex: 0 0 auto;
	border-radius: 50%;
	background: currentColor;
	content: '';
}

body.woocommerce-view-order .ctsys-estado--completado {
	color: var(--ct-verde);
}

body.woocommerce-view-order .ctsys-estado--completado::before {
	content: none;
}

body.woocommerce-view-order .ctsys-estado--preparando,
body.woocommerce-view-order .ctsys-estado--pendiente {
	color: var(--ct-acento-azul);
}

body.woocommerce-view-order .ctsys-estado--inactivo {
	color: var(--ct-acento-azul);
}



.ctsys-pedido-pie {
	display: flex;
	justify-content: center;
	width: 100%;
	box-sizing: border-box;
	margin-top: 0;
	margin-inline: 0;
	padding: 1.5rem;
}

.ctsys-pedido-pie__acciones {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 0.75rem;
	width: 100%;
	margin-inline: auto;
}

.ctsys-pedido-pie__volver,
.ctsys-pedido-pie__pdf {
	display: inline-flex;
	min-height: 3rem;
	align-items: center;
	justify-content: center;
	gap: 0.55rem;
	box-sizing: border-box;
	border: 1px solid transparent;
	border-radius: var(--ct-radio-campo);
	padding: 0.75rem 1.25rem;
	font-size: 0.92rem;
	font-weight: 800;
	line-height: 1.2;
	text-align: center;
	text-decoration: none;
	text-transform: uppercase;
	transition: background var(--ct-transicion), border-color var(--ct-transicion), color var(--ct-transicion), transform var(--ct-transicion);
}

.ctsys-pedido-pie__volver {
	border-color: var(--ct-boton-principal-fondo);
	background: var(--ct-boton-principal-fondo);
	color: var(--ct-boton-principal-texto);
}

.ctsys-pedido-pie__pdf {
	border-color: var(--ct-boton-secundario-borde);
	background: var(--ct-superficie);
	color: var(--ct-boton-secundario-texto);
}

.ctsys-pedido-pie__volver:hover,
.ctsys-pedido-pie__volver:focus-visible {
	border-color: var(--ct-boton-principal-hover);
	background: var(--ct-boton-principal-hover);
	color: var(--ct-boton-principal-texto);
}

.ctsys-pedido-pie__pdf:hover,
.ctsys-pedido-pie__pdf:focus-visible {
	border-color: var(--ct-acento-azul);
	background: var(--ct-superficie-suave);
	color: var(--ct-tinta);
}

.ctsys-pedido-pie__volver:active,
.ctsys-pedido-pie__pdf:active {
	transform: translateY(1px);
}

@media (max-width: 767px) {
	.ctsys-informacion-pedido__resumen {
		grid-template-columns: 1fr;
	}

	.ctsys-informacion-pedido__resumen > section + section {
		border-top: 0;
		border-left: 0;
	}

	body.woocommerce-view-order .woocommerce-customer-details .woocommerce-columns--2 {
		grid-template-columns: 1fr;
	}

	body.woocommerce-view-order .woocommerce-customer-details .woocommerce-column--billing-address {
		border-right: 0;
		border-bottom: 1px solid var(--ct-borde);
	}

	.ctsys-pedido-pie {
		width: 100%;
		margin-inline: 0;
		padding: 1rem;
	}

	.ctsys-licencias,
	.ctsys-historial-pedido {
		padding: 1rem;
	}

	.ctsys-informacion-pedido__resumen > section,
	.ctsys-informacion-pedido__productos,
	.ctsys-facturacion {
		padding: 0 1rem 1rem;
	}

	.ctsys-informacion-pedido__resumen h3,
	.ctsys-informacion-pedido__productos h3,
	body.woocommerce-view-order .woocommerce-customer-details .woocommerce-column__title,
	.ctsys-facturacion > h2 {
		min-height: 3.25rem;
		margin-bottom: 1rem;
		padding: 0.85rem 0 0.7rem;
		font-size: 0.84rem;
	}

	.ctsys-informacion-pedido dl > div {
		grid-template-columns: 1.15rem minmax( 5.5rem, max-content ) minmax( 0, 1fr );
		column-gap: 0.55rem;
		min-height: 2.75rem;
	}

	.ctsys-informacion-pedido dt {
		font-size: 0.78rem;
	}

	.ctsys-informacion-pedido dd {
		font-size: 0.92rem;
	}

	.ctsys-facturacion__fila {
		min-height: 2.75rem;
		font-size: 0.94rem;
	}

	.ctsys-licencias__clave {
		flex-wrap: wrap;
		align-items: center;
	}

	.ctsys-licencias__clave code {
		min-width: 0;
		flex: 1 1 12rem;
	}

	.ctsys-licencias .ctsys-licencias__copiar.button {
		margin-left: auto;
	}

	.ctsys-facturacion > h2 {
		margin-inline: 0;
		padding-inline: 0;
	}

	html body.ctsys-cuenta.woocommerce-view-order .storex-content > #post-section.st-py-default {
		padding-top: var(--ct-separacion-menu-pagina-mobile) !important;
	}

	.ctsys-informacion-pedido__tabla-wrap,
	.ctsys-historial-pedido__tabla-wrap {
		max-width: 100%;
		-webkit-overflow-scrolling: touch;
		overscroll-behavior-inline: contain;
	}

	.ctsys-informacion-pedido table,
	.ctsys-historial-pedido table {
		min-width: 36rem;
	}

	.ctsys-informacion-pedido th,
	.ctsys-historial-pedido th {
		padding: 0.8rem 1rem;
	}

	.ctsys-informacion-pedido td,
	.ctsys-historial-pedido td {
		padding: 0.8rem 1rem;
	}

	.ctsys-informacion-pedido th,
	.ctsys-historial-pedido th {
		font-size: 0.9rem;
	}

	.ctsys-informacion-pedido td,
	.ctsys-historial-pedido td {
		font-size: 1rem;
	}

	.ctsys-informacion-pedido__producto {
		min-width: 16rem;
	}

	.ctsys-historial-pedido .ctsys-estado {
		font-size: 1rem;
	}
}


/* En la cuenta, el clearfix del wrapper y el gutter móvil de Bootstrap
 * reservan 48px + 48px antes del primer bloque. En el detalle de pedido
 * ese espacio no es contenido: la separación debe venir del token de página. */
@media (max-width: 991px) {
	body.ctsys-cuenta.woocommerce-view-order #post-section > .container > .row {
		margin-top: 0;
	}

	body.ctsys-cuenta.woocommerce-view-order #post-section > .container > .row > .col-lg-9 {
		margin-top: 0;
	}

}


/* Lista de pedidos: tabla limpia, sin insignias ni botones cromáticos dentro de las filas. */

/* Estado vacío nativo de WooCommerce: solo se modifica su presentación. */
body.woocommerce-orders .woocommerce-info {
	position: relative;
	box-sizing: border-box;
	display: grid;
	grid-template-columns: minmax(190px, 34%) minmax(0, 1fr);
	grid-template-rows: auto auto auto;
	align-items: center;
	column-gap: clamp(1.5rem, 4vw, 3.5rem);
	row-gap: .8rem;
	width: 100%;
	min-height: 21rem;
	overflow: hidden;
	margin: 0;
	padding: clamp(2rem, 4vw, 3.25rem);
	border: 1px solid #e5e5e5;
	border-radius: 1.25rem;
	background: var(--ct-superficie-suave);
	color: var(--ct-tinta);
	font-size: clamp(1.75rem, 3vw, 2.15rem);
	font-weight: 800;
	letter-spacing: -.025em;
	line-height: 1.12;
	box-shadow: 0 10px 28px rgba(0, 0, 0, .06);
}

body.woocommerce-orders .woocommerce-info::before {
	position: static;
	grid-column: 1;
	grid-row: 1 / span 3;
	display: block;
	width: min(100%, 14rem);
	aspect-ratio: 220 / 190;
	margin: 0 auto;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 240 200'%3E%3Cellipse cx='120' cy='174' rx='76' ry='18' fill='%23F3F3F3'/%3E%3Cpath d='M120 22v25M84 43l16 17M156 43l-16 17' stroke='%235C5C5C' stroke-width='6' stroke-linecap='round'/%3E%3Cpath d='M72 103 120 127v57l-48-24z' fill='%23737373'/%3E%3Cpath d='m120 127 48-24v57l-48 24z' fill='%235C5C5C'/%3E%3Cpath d='m120 80-48 23-32-19 48-21z' fill='%23D4D4D4'/%3E%3Cpath d='m120 80 48 23 32-19-48-21z' fill='%23E5E5E5'/%3E%3Cpath d='m72 103 48-23 48 23-48 26z' fill='%23262626'/%3E%3Cpath d='m72 103 48-23v49z' fill='%235C5C5C'/%3E%3Cpath d='m168 103-48-23v49z' fill='%23737373'/%3E%3Cpath d='m72 103 48 26-20 28-60-39z' fill='%238A8A8A'/%3E%3Cpath d='m168 103-48 26 20 28 60-39z' fill='%23737373'/%3E%3C/svg%3E") center / contain no-repeat;
	content: '';
	pointer-events: none;
}

body.woocommerce-orders .woocommerce-info::after {
	grid-column: 2;
	grid-row: 2;
	margin: -.55rem 0 0;
	color: var(--ct-tinta-suave);
	font-size: clamp(1rem, 1.5vw, 1.15rem);
	font-weight: 400;
	line-height: 1.55;
	content: 'Explora nuestro catálogo y encuentra la licencia ideal para ti.';
}

body.woocommerce-orders .woocommerce-info .woocommerce-Button.button {
	grid-column: 2;
	grid-row: 3;
	display: inline-flex;
	justify-self: start;
	width: fit-content;
	max-width: 100%;
	min-height: 3.75rem;
	align-items: center;
	justify-content: center;
	gap: .8rem;
	margin: 0;
	border: 0;
	border-radius: var(--ct-radio-pill);
	background: var(--ct-boton-principal-fondo);
	padding: .85rem 1.8rem;
	color: var(--ct-superficie);
	font-size: 0;
	font-weight: 800;
	line-height: 1.2;
	text-decoration: none;
	transition: background-color var(--ct-transicion), transform var(--ct-transicion), box-shadow var(--ct-transicion);
}

body.woocommerce-orders .woocommerce-info .woocommerce-Button.button::before {
	font-size: 1rem;
	content: 'Explorar productos';
}

body.woocommerce-orders .woocommerce-info .woocommerce-Button.button::after {
	font-size: 1.45rem;
	line-height: 1;
	content: '→';
}

body.woocommerce-orders .woocommerce-info .woocommerce-Button.button:hover,
body.woocommerce-orders .woocommerce-info .woocommerce-Button.button:focus-visible {
	background: var(--ct-boton-principal-hover);
	color: var(--ct-boton-principal-texto);
	transform: translateY(-2px);
	box-shadow: 0 8px 18px rgba(0, 0, 0, .12);
}

body.woocommerce-orders .woocommerce-info .woocommerce-Button.button:focus-visible {
	outline: var(--ct-foco-teclado);
	outline-offset: 4px;
}

body.woocommerce-orders .woocommerce-orders-table {
	table-layout: fixed;
	border-collapse: separate;
	border-spacing: 0;
	border-radius: 16px;
	overflow: hidden;
}

body.woocommerce-orders .woocommerce-orders-table thead th,
body.woocommerce-orders .woocommerce-orders-table tbody th,
body.woocommerce-orders .woocommerce-orders-table tbody td {
	font-variant-numeric: tabular-nums;
}

body.woocommerce-orders .woocommerce-orders-table thead th {
	padding: 10px 14px;
	border-bottom: 1px solid var(--ct-borde);
	background: var(--ct-superficie);
	color: var(--ct-tinta);
	font-size: 0.86rem;
	letter-spacing: 0.035em;
}

body.woocommerce-orders .woocommerce-orders-table tbody th,
body.woocommerce-orders .woocommerce-orders-table tbody td {
	padding: 5px 14px;
	border-top: 1px solid var(--ct-borde-suave);
	background: transparent;
	color: var(--ct-tinta);
	font-size: 1rem;
}

body.woocommerce-orders .woocommerce-orders-table tbody tr:nth-child(even) {
	background: transparent;
}

body.woocommerce-orders .woocommerce-orders-table .woocommerce-orders-table__header-order-number,
body.woocommerce-orders .woocommerce-orders-table .woocommerce-orders-table__cell-order-number {
	width: 17%;
	text-align: left;
}

body.woocommerce-orders .woocommerce-orders-table .woocommerce-orders-table__header-ctsys-products,
body.woocommerce-orders .woocommerce-orders-table .woocommerce-orders-table__cell-ctsys-products {
	width: 16%;
}

body.woocommerce-orders .woocommerce-orders-table .woocommerce-orders-table__header-order-status,
body.woocommerce-orders .woocommerce-orders-table .woocommerce-orders-table__cell-order-status {
	width: 22%;
}

body.woocommerce-orders .woocommerce-orders-table .woocommerce-orders-table__header-order-total,
body.woocommerce-orders .woocommerce-orders-table .woocommerce-orders-table__cell-order-total {
	width: 18%;
	text-align: right;
}

body.woocommerce-orders .woocommerce-orders-table .woocommerce-orders-table__header-order-date,
body.woocommerce-orders .woocommerce-orders-table .woocommerce-orders-table__cell-order-date {
	width: 27%;
	text-align: right;
}

body.woocommerce-orders .woocommerce-orders-table .ctsys-historial__fecha {
	display: grid;
	grid-template-columns: minmax(max-content, 1fr) 44px 44px;
	gap: 0;
	width: 100%;
	margin: 0;
	align-items: center;
}

body.woocommerce-orders .woocommerce-orders-table .ctsys-historial__fecha time {
	text-align: right;
}

body.woocommerce-orders .woocommerce-orders-table .ctsys-estado {
	display: inline;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	color: var(--ct-acento-azul);
	font-size: 1rem;
	font-weight: 700;
}

body.woocommerce-orders .woocommerce-orders-table .ctsys-estado--completado {
	color: var(--ct-verde);
}

body.woocommerce-orders .woocommerce-orders-table .ctsys-historial__ojo {
	display: inline-flex;
	width: 44px;
	height: 44px;
	border: 0;
	border-radius: 0;
	background: transparent;
	color: var(--ct-acento-azul);
	box-shadow: none;
	transition: color var(--ct-transicion);
}

body.woocommerce-orders .woocommerce-orders-table .ctsys-historial__ojo:hover,
body.woocommerce-orders .woocommerce-orders-table .ctsys-historial__ojo:focus {
	background: transparent;
	color: var(--ct-acento-azul);
}

body.woocommerce-orders .woocommerce-orders-table .ctsys-historial__factura {
	display: inline-flex;
	width: 44px;
	height: 44px;
	border: 0;
	border-radius: 0;
	background: transparent;
	color: var(--ct-acento-azul);
	box-shadow: none;
	transition: color var(--ct-transicion);
}

body.woocommerce-orders .woocommerce-orders-table .ctsys-historial__factura:hover,
body.woocommerce-orders .woocommerce-orders-table .ctsys-historial__factura:focus-visible {
	background: transparent;
	color: #333333;
}

body.woocommerce-orders .woocommerce-Pagination {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	justify-content: flex-start;
	margin: 24px 0 0;
}

body.woocommerce-orders .woocommerce-Pagination .woocommerce-button {
	display: inline-flex;
	min-height: 44px;
	align-items: center;
	justify-content: center;
	margin: 0;
	border: 1px solid var(--ct-borde);
	border-radius: var(--ct-radio-campo);
	background: var(--ct-superficie);
	padding: 10px 18px;
	color: var(--ct-acento-azul);
	font-size: 1rem;
	font-weight: 700;
	line-height: 1.2;
	text-decoration: none;
	transition: border-color var(--ct-transicion), background var(--ct-transicion), color var(--ct-transicion);
}

body.woocommerce-orders .woocommerce-Pagination .woocommerce-button:hover,
body.woocommerce-orders .woocommerce-Pagination .woocommerce-button:focus-visible {
	border-color: var(--ct-acento-azul);
	background: var(--ct-hover-sutil);
	color: var(--ct-acento-azul);
}

@media (max-width: 768px) {
	body.woocommerce-orders .woocommerce-orders-table {
		table-layout: auto;
	}

	body.woocommerce-orders .woocommerce-orders-table thead th {
		padding: 0.7rem 0.35rem;
		font-size: 0.72rem;
	}

	body.woocommerce-orders .woocommerce-orders-table tbody th,
	body.woocommerce-orders .woocommerce-orders-table tbody td {
		padding: 0.25rem 0.35rem;
		font-size: 0.86rem;
	}

	body.woocommerce-orders .woocommerce-orders-table .ctsys-estado {
		font-size: 0.86rem;
	}

	body.woocommerce-orders .woocommerce-orders-table .ctsys-historial__ojo {
		width: 44px;
		height: 44px;
	}

	body.woocommerce-orders .woocommerce-orders-table .ctsys-historial__ojo svg {
		width: 18px;
		height: 18px;
	}

	body.woocommerce-orders .woocommerce-Pagination {
		gap: 8px;
		margin-top: 16px;
	}

	body.woocommerce-orders .woocommerce-Pagination .woocommerce-button {
		font-size: 0.92rem;
	}
}


/* Paginación de pedidos: números reales y flechas solo para páginas existentes. */
body.woocommerce-orders .woocommerce-pagination.woocommerce-Pagination {
	display: none;
}

body.woocommerce-orders .ctsys-pedidos-paginacion {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin: 24px 0 0;
}

body.woocommerce-orders .ctsys-pedidos-paginacion {
		gap: 6px;
		margin-top: 16px;
	}

	body.woocommerce-orders .ctsys-pedidos-paginacion a {
		min-width: 44px;
		height: 44px;
		font-size: 0.92rem;
	}
}

@media (max-width: 991px) {
	body.woocommerce-orders .woocommerce-info {
		grid-template-columns: minmax(150px, 30%) minmax(0, 1fr);
		gap: 1.5rem;
		padding: 2rem;
	}
}

@media (max-width: 767px) {
	body.woocommerce-orders .woocommerce-info {
		grid-template-columns: 1fr;
		gap: 1.25rem;
		min-height: 0;
		padding: 1.5rem 1.25rem 1.75rem;
		text-align: center;
	}

	body.woocommerce-orders .woocommerce-info::before {
		grid-column: 1;
		grid-row: 1;
		width: min(58vw, 11rem);
	}

	body.woocommerce-orders .woocommerce-info::after {
		grid-column: 1;
		grid-row: 3;
	}

	body.woocommerce-orders .woocommerce-info {
		font-size: clamp(1.5rem, 7vw, 1.75rem);
	}

	body.woocommerce-orders .woocommerce-info::after {
		margin-top: -.25rem;
		font-size: 1rem;
	}

	body.woocommerce-orders .woocommerce-info .woocommerce-Button.button {
		grid-column: 1;
		grid-row: 4;
		width: 100%;
	}
}

/* Detalle de pedido: bloques compactos, con divisiones en lugar de tarjetas anidadas. */
body.woocommerce-view-order .woocommerce-MyAccount-content {
	gap: 16px;
}
body.woocommerce-view-order .ctsys-licencias,
body.woocommerce-view-order .ctsys-historial-pedido,
body.woocommerce-view-order .ctsys-guias-pedido,
body.woocommerce-view-order .ctsys-facturacion,
body.woocommerce-view-order .ctsys-informacion-pedido__resumen > section,
body.woocommerce-view-order .ctsys-informacion-pedido__productos,
body.woocommerce-view-order .ctsys-pedido-pie {
	min-width: 0;
	padding: 16px 0;
	border: 0;
	border-bottom: 1px solid var(--ct-borde);
	border-radius: 0;
	background: transparent;
	box-shadow: none;
}
body.woocommerce-view-order .ctsys-informacion-pedido__resumen {
	gap: 12px 24px;
}
body.woocommerce-view-order .ctsys-informacion-pedido__resumen > section {
	min-height: 0;
}
body.woocommerce-view-order .ctsys-licencias__cabecera {
	margin-bottom: 12px;
}
body.woocommerce-view-order .ctsys-licencias__cabecera h2,
body.woocommerce-view-order .ctsys-historial-pedido h2,
body.woocommerce-view-order .ctsys-guias-pedido > h2,
body.woocommerce-view-order .ctsys-facturacion > h2,
body.woocommerce-view-order .ctsys-informacion-pedido__resumen h3,
body.woocommerce-view-order .ctsys-informacion-pedido__productos h3 {
	min-height: 0;
	margin: 0 0 12px;
	padding: 0;
	border: 0;
	color: var(--ct-tinta);
	font-size: 1.05rem;
	font-weight: 650;
	letter-spacing: 0;
	line-height: 1.35;
	text-transform: none;
}
body.woocommerce-view-order .ctsys-licencias__cabecera h2::after,
body.woocommerce-view-order .ctsys-historial-pedido h2::after {
	content: none;
}
body.woocommerce-view-order .ctsys-informacion-pedido dl > div,
body.woocommerce-view-order .ctsys-facturacion__fila {
	min-height: 0;
	padding-block: 5px;
}
body.woocommerce-view-order .ctsys-informacion-pedido dt {
	font-size: .875rem;
	font-weight: 600;
	letter-spacing: 0;
	text-transform: none;
}
body.woocommerce-view-order .ctsys-informacion-pedido dd,
body.woocommerce-view-order .ctsys-facturacion__fila {
	font-size: .9rem;
}
body.woocommerce-view-order .ctsys-informacion-pedido th,
body.woocommerce-view-order .ctsys-informacion-pedido td,
body.woocommerce-view-order .ctsys-historial-pedido th,
body.woocommerce-view-order .ctsys-historial-pedido td {
	padding: 10px 12px;
	font-size: .875rem;
}
body.woocommerce-view-order .ctsys-informacion-pedido tbody tr:nth-child(even),
body.woocommerce-view-order .ctsys-historial-pedido tbody tr:nth-child(even) {
	background: transparent;
}
body.woocommerce-view-order .ctsys-licencias__producto + .ctsys-licencias__producto {
	margin-top: 12px;
}
body.woocommerce-view-order .ctsys-guia-pedido {
	line-height: 1.5;
}
@media (max-width: 767px) {
	body.woocommerce-view-order .woocommerce-MyAccount-content {
		gap: 8px;
	}
	body.woocommerce-view-order .ctsys-informacion-pedido__resumen {
		gap: 0;
	}
	body.woocommerce-view-order .ctsys-informacion-pedido dl > div {
		grid-template-columns: 1.15rem minmax(5.5rem, max-content) minmax(0, 1fr);
	}
	body.woocommerce-view-order .ctsys-informacion-pedido table,
	body.woocommerce-view-order .ctsys-historial-pedido table {
		min-width: 32rem;
	}
}
