/**
 * Pagine legali — contratto quadro e documenti lunghi (palette Vitacomoda).
 */

.vc-legal-contract {
	--vc-legal-blue: #0445af;
	--vc-legal-cyan: #04b8d8;
	--vc-legal-cyclamen: #d6006e;
	--vc-legal-ink: #1e2a39;
	--vc-legal-muted: #64748b;
	--vc-legal-line: rgba(4, 69, 175, 0.14);
	--vc-legal-radius: 18px;
	max-width: 52rem;
	margin: 0 auto 3rem;
	padding: 0 1rem 2rem;
	box-sizing: border-box;
	color: var(--vc-legal-ink);
	font-size: 1rem;
	line-height: 1.65;
}

.vc-legal-contract__draft {
	border: 1.5px solid #d4a200;
	background: linear-gradient(180deg, #fffbeb 0%, #fff7e1 100%);
	padding: 0.85rem 1rem;
	margin: 0 0 1.5rem;
	border-radius: 12px;
	font-size: 0.88rem;
	line-height: 1.5;
}

.vc-legal-contract__hero {
	position: relative;
	margin: 0 0 1.75rem;
	padding: 1.5rem 1.35rem 1.35rem;
	border-radius: var(--vc-legal-radius);
	background:
		linear-gradient(135deg, rgba(4, 69, 175, 0.08) 0%, rgba(214, 0, 110, 0.06) 55%, rgba(4, 184, 216, 0.08) 100%);
	border: 1.5px solid rgba(214, 0, 110, 0.2);
	box-shadow: 0 12px 32px -16px rgba(4, 69, 175, 0.25);
	overflow: hidden;
}

.vc-legal-contract__hero::before {
	content: "";
	position: absolute;
	inset: 0 0 auto 0;
	height: 4px;
	background: linear-gradient(90deg, var(--vc-legal-blue) 0%, var(--vc-legal-cyclamen) 50%, var(--vc-legal-cyan) 100%);
}

.vc-legal-contract__eyebrow {
	margin: 0 0 0.5rem;
	font-size: 0.72rem;
	font-weight: 800;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--vc-legal-cyclamen);
}

.vc-legal-contract__title {
	margin: 0 0 0.85rem;
	font-size: clamp(1.15rem, 2.8vw, 1.55rem);
	font-weight: 800;
	line-height: 1.28;
	color: var(--vc-legal-blue);
}

.vc-legal-contract__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 0.45rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.vc-legal-contract__meta li {
	display: inline-flex;
	align-items: center;
	padding: 0.35rem 0.7rem;
	border-radius: 999px;
	font-size: 0.75rem;
	font-weight: 700;
	color: var(--vc-legal-blue);
	background: #ffffff;
	border: 1px solid var(--vc-legal-line);
	box-shadow: 0 2px 8px -4px rgba(4, 69, 175, 0.2);
}

.vc-legal-contract__meta strong {
	margin-right: 0.25rem;
	color: var(--vc-legal-cyclamen);
}

.vc-legal-contract__layout {
	display: grid;
	gap: 1.5rem;
	align-items: start;
}

@media (min-width: 960px) {
	.vc-legal-contract__layout {
		grid-template-columns: minmax(0, 11.5rem) minmax(0, 1fr);
	}
}

.vc-legal-contract__toc {
	position: sticky;
	top: 1rem;
	padding: 0.85rem 0.75rem;
	border-radius: 14px;
	background: #ffffff;
	border: 1px solid var(--vc-legal-line);
	box-shadow: 0 8px 24px -14px rgba(4, 69, 175, 0.2);
}

.vc-legal-contract__toc-title {
	margin: 0 0 0.55rem;
	font-size: 0.68rem;
	font-weight: 800;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--vc-legal-muted);
}

.vc-legal-contract__toc ol {
	margin: 0;
	padding-left: 1.1rem;
	font-size: 0.78rem;
	line-height: 1.45;
}

.vc-legal-contract__toc a {
	color: var(--vc-legal-blue);
	font-weight: 600;
	text-decoration: none;
}

.vc-legal-contract__toc a:hover,
.vc-legal-contract__toc a:focus-visible {
	color: var(--vc-legal-cyclamen);
	text-decoration: underline;
}

.vc-legal-contract__body section {
	margin: 0 0 1.35rem;
	padding: 1.1rem 1.15rem;
	border-radius: 14px;
	background: #ffffff;
	border: 1px solid var(--vc-legal-line);
	box-shadow: 0 4px 18px -12px rgba(4, 69, 175, 0.15);
	scroll-margin-top: 1rem;
}

.vc-legal-contract__body h2 {
	margin: 0 0 0.75rem;
	padding-bottom: 0.45rem;
	border-bottom: 2px solid rgba(214, 0, 110, 0.22);
	font-size: 1.02rem;
	font-weight: 800;
	line-height: 1.35;
	color: var(--vc-legal-blue);
}

.vc-legal-contract__body h3 {
	margin: 1rem 0 0.45rem;
	font-size: 0.92rem;
	font-weight: 800;
	color: var(--vc-legal-ink);
}

.vc-legal-contract__body p {
	margin: 0 0 0.75rem;
}

.vc-legal-contract__body p:last-child,
.vc-legal-contract__body ul:last-child,
.vc-legal-contract__body ol:last-child {
	margin-bottom: 0;
}

.vc-legal-contract__body ul,
.vc-legal-contract__body ol {
	margin: 0 0 0.75rem;
	padding-left: 1.25rem;
}

.vc-legal-contract__body li {
	margin: 0.35rem 0;
}

.vc-legal-contract__body li::marker {
	color: var(--vc-legal-cyclamen);
	font-weight: 700;
}

.vc-legal-contract__body a {
	color: var(--vc-legal-blue);
	font-weight: 600;
	word-break: break-word;
}

.vc-legal-contract__preamble {
	background: linear-gradient(180deg, #ffffff 0%, #f8faff 100%);
}

.vc-legal-contract__clause-list {
	list-style: none;
	padding-left: 0;
}

.vc-legal-contract__clause-list > li {
	position: relative;
	margin: 0.55rem 0;
	padding: 0.55rem 0.65rem 0.55rem 2.15rem;
	border-radius: 10px;
	background: rgba(4, 69, 175, 0.04);
	border: 1px solid rgba(4, 69, 175, 0.1);
}

.vc-legal-contract__clause-list > li::before {
	content: attr(data-label);
	position: absolute;
	left: 0.55rem;
	top: 0.55rem;
	font-size: 0.72rem;
	font-weight: 800;
	color: #ffffff;
	background: linear-gradient(135deg, var(--vc-legal-cyclamen) 0%, #ff4fa3 100%);
	width: 1.35rem;
	height: 1.35rem;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	line-height: 1;
}

.vc-legal-contract__defs {
	counter-reset: vc-def;
	list-style: none;
	padding-left: 0;
}

.vc-legal-contract__defs > li {
	counter-increment: vc-def;
	position: relative;
	margin: 0.55rem 0;
	padding: 0.65rem 0.75rem 0.65rem 2.5rem;
	border-radius: 10px;
	background: #f8faff;
	border: 1px solid rgba(4, 69, 175, 0.1);
}

.vc-legal-contract__defs > li::before {
	content: counter(vc-def) ".";
	position: absolute;
	left: 0.75rem;
	top: 0.65rem;
	font-weight: 800;
	color: var(--vc-legal-cyclamen);
}

.vc-legal-contract__defs strong {
	color: var(--vc-legal-blue);
}

@media (max-width: 959px) {
	.vc-legal-contract__toc {
		position: static;
	}
}

@media (prefers-reduced-motion: reduce) {
	.vc-legal-contract__toc a {
		transition: none;
	}
}

/* Evita doppio titolo pagina WP: l'hero del contratto è sufficiente */
body.page-termini-piattaforma .entry-hero,
body.page-termini-piattaforma .entry-hero-container,
body.page-termini-piattaforma .page-title {
	display: none !important;
}

body.page-termini-piattaforma .content-bg,
body.page-termini-piattaforma .content-area {
	background: linear-gradient(168deg, #f4f8fc 0%, #ffffff 42%, #f0f9ff 100%);
}

body.page-privacy-marketplace .entry-hero,
body.page-privacy-marketplace .entry-hero-container,
body.page-privacy-marketplace .page-title {
	display: none !important;
}

body.page-privacy-marketplace .content-bg,
body.page-privacy-marketplace .content-area {
	background: linear-gradient(168deg, #f4f8fc 0%, #ffffff 42%, #f0f9ff 100%);
}

.vc-legal-contract__table-wrap {
	overflow-x: auto;
	margin: 0 0 0.75rem;
	border-radius: 12px;
	border: 1px solid var(--vc-legal-line);
}

.vc-legal-contract__table {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.82rem;
	line-height: 1.45;
}

.vc-legal-contract__table th,
.vc-legal-contract__table td {
	padding: 0.55rem 0.65rem;
	border-bottom: 1px solid var(--vc-legal-line);
	text-align: left;
	vertical-align: top;
}

.vc-legal-contract__table thead th {
	background: linear-gradient(180deg, #f8faff 0%, #eef4ff 100%);
	color: var(--vc-legal-blue);
	font-weight: 800;
	font-size: 0.78rem;
}

.vc-legal-contract__table tbody tr:last-child td {
	border-bottom: none;
}

.vc-legal-contract__profile {
	margin: 0.65rem 0;
	padding: 0.75rem 0.85rem;
	border-radius: 12px;
	background: #f8faff;
	border: 1px solid rgba(4, 69, 175, 0.12);
}

.vc-legal-contract__profile h3 {
	margin: 0 0 0.45rem;
	font-size: 0.92rem;
	color: var(--vc-legal-cyclamen);
}

.vc-legal-contract__contact-box {
	margin: 0.75rem 0 0;
	padding: 0.75rem 0.9rem;
	border-radius: 12px;
	background: linear-gradient(135deg, rgba(4, 69, 175, 0.06) 0%, rgba(214, 0, 110, 0.05) 100%);
	border: 1px solid rgba(214, 0, 110, 0.18);
}

.vc-legal-contract__contact-box p {
	margin: 0.25rem 0;
	font-size: 0.88rem;
}
