/* ==========================================================================
   Valnure Viaggi — stili del tema (front-end + editor)
   Convenzione: classi con prefisso .vv-
   ========================================================================== */

:root {
	--vv-line-light: rgba(239, 238, 234, 0.28);
	--vv-line-dark: var(--wp--preset--color--contrast);
	--vv-icon-v: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 18' fill='none' stroke='%23A5834F' stroke-width='1.4'%3E%3Cpath d='M1.5 1.5 10 16.5 18.5 1.5'/%3E%3Cpath d='M5.5 1.5 10 9.5 14.5 1.5'/%3E%3C/svg%3E");
}

/* Nessuno spazio tra header, contenuto e footer (il blockGap globale li separerebbe) */
.wp-site-blocks > * { margin-block-start: 0; margin-block-end: 0; }

html { scroll-behavior: smooth; }
body { -webkit-font-smoothing: antialiased; }

/* ---------- Titoli: parte in corsivo ---------- */
h1 em, h2 em, h3 em, h4 em {
	font-style: italic;
	color: var(--wp--preset--color--primary);
}
.has-primary-background-color h1 em,
.has-primary-background-color h2 em,
.has-primary-background-color h3 em { color: var(--wp--preset--color--gold); }
.vv-hero h1 em { color: inherit; }

/* ---------- Eyebrow (etichetta sopra i titoli) ---------- */
.is-style-eyebrow,
.is-style-eyebrow-v {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.6rem;
	margin: 0;
	font-size: var(--wp--preset--font-size--x-small);
	font-weight: 400;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	line-height: 1.2;
}
.is-style-eyebrow.has-text-align-left,
.is-style-eyebrow-v.has-text-align-left { justify-content: flex-start; }
.is-style-eyebrow-v::before {
	content: "";
	flex: 0 0 auto;
	width: 1.1rem;
	height: 1rem;
	background: var(--vv-icon-v) center / contain no-repeat;
}

/* ---------- Link con freccia e filetto ---------- */
.is-style-link-arrow,
.is-style-link-arrow-full {
	margin: 0;
	font-size: var(--wp--preset--font-size--x-small);
	font-weight: 400;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	line-height: 1.2;
}
.is-style-link-arrow a,
.is-style-link-arrow-full a {
	display: inline-block;
	padding-bottom: 0.35rem;
	border-bottom: 1px solid currentColor;
	color: inherit;
	text-decoration: none;
	transition: opacity .2s ease, padding-right .2s ease;
}
.is-style-link-arrow a:hover,
.is-style-link-arrow-full a:hover { opacity: .65; }

/* variante: filetto a tutta larghezza della colonna (card categorie) */
.is-style-link-arrow-full { display: block; padding-bottom: 1.1rem; border-bottom: 1px solid var(--vv-line-dark); }
.is-style-link-arrow-full a { border-bottom: 0; padding-bottom: 0; color: var(--wp--preset--color--primary); }

/* ---------- Pulsanti ---------- */
.wp-block-button .wp-block-button__link { transition: background-color .2s ease, color .2s ease; }
.wp-block-button.is-style-light .wp-block-button__link {
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--primary);
}
.wp-block-button.is-style-light .wp-block-button__link:hover {
	background: var(--wp--preset--color--gold);
	color: var(--wp--preset--color--contrast);
}
.wp-block-button.is-style-outline .wp-block-button__link {
	background: transparent;
	color: currentColor;
	border: 1px solid currentColor;
}
.wp-block-button.is-style-block .wp-block-button__link { width: 100%; text-align: center; }

/* ---------- Header ---------- */
.vv-header { border-bottom: 1px solid rgba(239, 238, 234, 0.18); }
.vv-header__inner { min-height: 96px; gap: 2rem; }
.vv-logo { margin: 0; flex: 0 0 auto; }
.vv-logo img { display: block; height: auto; }
.vv-nav { flex: 1 1 auto; }
.vv-nav .wp-block-navigation__container { gap: clamp(1.25rem, 3vw, 3rem); }
.vv-nav .wp-block-navigation-item__content,
.vv-nav a {
	font-size: var(--wp--preset--font-size--x-small);
	font-weight: 400;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	text-decoration: none;
	color: var(--wp--preset--color--base);
}
.vv-nav a:hover { color: var(--wp--preset--color--gold); }
.vv-nav .vv-nav-cta > .wp-block-navigation-item__content {
	padding: 0.85rem 1.1rem;
	border: 1px solid var(--wp--preset--color--base);
}
.vv-nav .vv-nav-cta > .wp-block-navigation-item__content:hover {
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--primary);
}
.wp-block-navigation__responsive-container.is-menu-open { background: var(--wp--preset--color--primary); color: var(--wp--preset--color--base); }
.vv-header .wp-block-navigation__responsive-container-open { color: var(--wp--preset--color--base); }

.vv-search { flex: 0 0 auto; }
.vv-search .wp-block-search__inside-wrapper { border: 0; border-bottom: 1px solid var(--vv-line-light); padding: 0; background: transparent; }
.vv-search .wp-block-search__input {
	border: 0; background: transparent; padding: 0.55rem 0;
	font-size: var(--wp--preset--font-size--small); font-weight: 300; color: var(--wp--preset--color--base);
}
.vv-search .wp-block-search__input::placeholder { color: var(--wp--preset--color--gold); opacity: .9; }
.vv-search .wp-block-search__button { background: transparent; border: 0; color: var(--wp--preset--color--base); padding: 0 0.5rem 0 0; order: -1; }

/* pulsante rotondo (WhatsApp, social) */
.vv-circle-btn,
.vv-social .wp-social-link a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 46px;
	height: 46px;
	padding: 0;
	border: 1px solid var(--wp--preset--color--gold);
	border-radius: 50%;
	color: var(--wp--preset--color--base);
	background: transparent;
	text-decoration: none;
	transition: background-color .2s ease, color .2s ease;
}
.vv-circle-btn:hover { background: var(--wp--preset--color--gold); color: var(--wp--preset--color--primary); }
.vv-circle-btn svg { width: 20px; height: 20px; }
.vv-social { gap: 0.75rem; }
.vv-social .wp-social-link { background: transparent !important; width: auto; height: auto; }
.vv-social .wp-social-link a { width: 42px; height: 42px; padding: 0; }
.vv-social .wp-social-link svg { width: 18px; height: 18px; }
.vv-social--dark .wp-social-link a { border-color: var(--wp--preset--color--primary); color: var(--wp--preset--color--primary); }
.vv-social--dark .wp-social-link a:hover { background: var(--wp--preset--color--primary); color: var(--wp--preset--color--base); }
.vv-social--light .wp-social-link a { border-color: rgba(239, 238, 234, 0.5); color: var(--wp--preset--color--base); }
.vv-social--light .wp-social-link a:hover { background: var(--wp--preset--color--base); color: var(--wp--preset--color--primary); }

@media (max-width: 1100px) {
	.vv-header .vv-search { display: none; }
}
@media (max-width: 781px) {
	.vv-header__inner { min-height: 72px; }
	.vv-logo img { width: 160px !important; }
	.vv-header .vv-circle-btn { display: none; }
}

/* ---------- Hero ---------- */
.vv-hero {
	position: relative;
	isolation: isolate;
	display: flex;
	align-items: center;
	min-height: clamp(34rem, 80vh, 48rem);
	margin-block-start: 0;
	background-color: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--base);
}
.vv-hero::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: linear-gradient(90deg, rgba(12, 65, 81, 0.55) 0%, rgba(12, 65, 81, 0.08) 60%, rgba(12, 65, 81, 0) 100%);
}
.vv-hero > .wp-block-group,
.vv-hero > * { position: relative; }
.vv-hero__title { margin: 0; }
.vv-hero__tagline { margin: 0; font-weight: 200; letter-spacing: 0.01em; }
.vv-hero__text { max-width: 36rem; }

/* ---------- Sezioni generiche ---------- */
.vv-section { margin-block: 0; }
.vv-section__head { text-align: center; }
.vv-section__head .wp-block-heading { margin: 0; }
.vv-section__lead { max-width: 46rem; margin-inline: auto; }

/* ---------- Categorie viaggio (2 colonne con immagine) ---------- */
.vv-categories .wp-block-image { margin: 0; }
.vv-categories .wp-block-image img { width: 100%; height: auto; }
.vv-category { gap: 0; }
.vv-category .wp-block-heading { margin: 2.75rem 0 1rem; }
.vv-category .is-style-link-arrow { margin-top: 0; }

/* ---------- Card viaggio + griglia ---------- */
.vv-trip-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	column-gap: 2rem;
	row-gap: 4rem;
}
.vv-trip-grid > * { margin: 0 !important; }
.vv-trip { gap: 0; position: relative; }
.vv-trip__media { position: relative; margin: 0 0 1.5rem; }
.vv-trip__media .wp-block-image { margin: 0; }
.vv-trip__media img {
	display: block; width: 100%; aspect-ratio: 4 / 5; object-fit: cover;
	box-shadow: var(--wp--preset--shadow--card);
}
.vv-badge {
	position: absolute; top: 14px; left: 14px; margin: 0;
	padding: 0.5rem 0.75rem;
	font-size: 0.6875rem; font-weight: 400; letter-spacing: 0.03em; text-transform: uppercase; line-height: 1;
	background: var(--wp--preset--color--base); color: var(--wp--preset--color--contrast);
}
.vv-badge--individuale { background: var(--wp--preset--color--primary); color: var(--wp--preset--color--base); }
.vv-trip__date {
	margin: 0 0 0.6rem;
	font-size: 0.75rem; font-weight: 400; letter-spacing: 0.04em; text-transform: uppercase; color: var(--wp--preset--color--gold-dark);
}
.vv-trip__title { margin: 0 0 1.1rem; }
.vv-trip__title a { color: inherit; text-decoration: none; }
.vv-trip .is-style-link-arrow { color: var(--wp--preset--color--contrast); }
.vv-trip .is-style-link-arrow a::after { content: none; }
.vv-trip-grid.is-paged > .vv-trip[hidden] { display: none; }

.vv-pager {
	display: flex; align-items: center; justify-content: center; gap: 1.5rem; margin-top: 3.5rem;
}
.vv-pager[hidden] { display: none; }
.vv-pager__btn {
	width: 48px; height: 48px; padding: 0; display: inline-flex; align-items: center; justify-content: center;
	border: 1px solid var(--wp--preset--color--contrast); border-radius: 50%; background: transparent;
	color: var(--wp--preset--color--contrast); cursor: pointer; transition: background-color .2s ease, color .2s ease;
}
.vv-pager__btn:hover:not(:disabled) { background: var(--wp--preset--color--primary); border-color: var(--wp--preset--color--primary); color: var(--wp--preset--color--base); }
.vv-pager__btn:disabled { opacity: .35; cursor: default; }
.vv-pager__btn--next { background: var(--wp--preset--color--primary); border-color: var(--wp--preset--color--primary); color: var(--wp--preset--color--base); }
.vv-pager__dots { display: flex; gap: 0.5rem; }
.vv-pager__dot { width: 28px; height: 2px; background: var(--wp--preset--color--contrast); opacity: .25; border: 0; padding: 0; cursor: pointer; }
.vv-pager__dot[aria-current="true"] { opacity: 1; }

@media (max-width: 1023px) { .vv-trip-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .vv-trip-grid { grid-template-columns: 1fr; } }

/* ---------- Servizi (righe numerate) ---------- */
.vv-services { position: relative; overflow: hidden; isolation: isolate; }
.vv-services::before {
	content: "";
	position: absolute;
	z-index: -1;
	top: 4rem;
	right: -6vw;
	width: min(48vw, 640px);
	aspect-ratio: 1 / 1.1;
	opacity: .1;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 440' fill='%23EFEEEA'%3E%3Cpath d='M0 0h74l142 330-37 70z'/%3E%3Cpath d='M120 0h74l142 330-37 70z'/%3E%3Cpath d='M400 0 330 150l-20-40L355 0z'/%3E%3C/svg%3E") center / contain no-repeat;
	pointer-events: none;
}
.vv-services__list { margin-top: 4.5rem; }
.vv-service-row {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	grid-template-areas: "body num";
	align-items: center;
	column-gap: 2rem;
	margin: 0;
	padding: 2.25rem 0;
	border-top: 1px solid var(--vv-line-light);
}
.vv-services__list > .vv-service-row:last-child { border-bottom: 1px solid var(--vv-line-light); }
.vv-service-row:nth-child(even) { grid-template-areas: "num body"; }
.vv-service-row__body { grid-area: body; margin: 0; max-width: 34rem; }
.vv-service-row:nth-child(even) .vv-service-row__body { justify-self: start; padding-left: 0; }
.vv-service-row__num {
	grid-area: num; margin: 0; justify-self: end;
	font-family: var(--wp--preset--font-family--display); font-size: var(--wp--preset--font-size--numeral); line-height: 1; color: var(--wp--preset--color--gold);
}
.vv-service-row:nth-child(even) .vv-service-row__num { justify-self: start; }
.vv-service-row__title { margin: 0 0 0.9rem; }
.vv-service-row__text { margin: 0 0 1.25rem; font-weight: 300; opacity: .92; }
.vv-service-row .is-style-link-arrow a { color: var(--wp--preset--color--base); }

@media (max-width: 781px) {
	.vv-service-row, .vv-service-row:nth-child(even) { grid-template-columns: 1fr; grid-template-areas: "num" "body"; row-gap: 1rem; padding: 1.75rem 0; }
	.vv-service-row__num, .vv-service-row:nth-child(even) .vv-service-row__num { justify-self: start; }
}

/* ---------- Contatti ---------- */
.vv-contact__cols { gap: 3rem; align-items: flex-start; }
.vv-contact__line { display: flex; align-items: center; gap: 1rem; margin: 0 0 1.25rem; font-size: var(--wp--preset--font-size--medium); }
.vv-contact__line::before {
	content: ""; flex: 0 0 auto; width: 1.1rem; height: 1.1rem; background-color: var(--wp--preset--color--primary);
	-webkit-mask: var(--vv-icon) center / contain no-repeat; mask: var(--vv-icon) center / contain no-repeat;
}
.vv-contact__line a { color: inherit; }
.vv-contact__line--pin { --vv-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.6'%3E%3Cpath d='M20 10c0 6-8 12-8 12s-8-6-8-12a8 8 0 0 1 16 0Z'/%3E%3Ccircle cx='12' cy='10' r='3'/%3E%3C/svg%3E"); }
.vv-contact__line--tel { --vv-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.6'%3E%3Cpath d='M22 16.9v3a2 2 0 0 1-2.2 2 19.8 19.8 0 0 1-8.6-3.1 19.5 19.5 0 0 1-6-6A19.8 19.8 0 0 1 2.1 4.2 2 2 0 0 1 4.1 2h3a2 2 0 0 1 2 1.7c.1 1 .4 1.9.7 2.8a2 2 0 0 1-.5 2.1L8.1 9.9a16 16 0 0 0 6 6l1.3-1.3a2 2 0 0 1 2.1-.4c.9.3 1.8.6 2.8.7a2 2 0 0 1 1.7 2Z'/%3E%3C/svg%3E"); }
.vv-contact__line--mail { --vv-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.6'%3E%3Crect x='3' y='5' width='18' height='14' rx='1'/%3E%3Cpath d='m3 7 9 6 9-6'/%3E%3C/svg%3E"); }
.vv-map { margin: 2rem 0 0; box-shadow: var(--wp--preset--shadow--card); }
.vv-map iframe { display: block; width: 100%; height: 260px; border: 0; }

/* ---------- Form contatti ---------- */
.vv-form-card {
	padding: clamp(1.5rem, 4vw, 3rem);
	background: var(--wp--preset--color--card);
	border: 1px solid var(--wp--preset--color--line);
}
.vv-form-card > .wp-block-heading { margin: 0 0 1.75rem; }
.vv-form-card > .wp-block-heading em { color: inherit; }
.vv-form__row { margin: 0 0 1.5rem; }
.vv-form__label {
	display: block; margin-bottom: 0.25rem;
	font-size: 0.6875rem; font-weight: 400; letter-spacing: 0.04em; text-transform: uppercase; color: var(--wp--preset--color--ink-soft);
}
.vv-form__field {
	display: block; width: 100%; padding: 0.6rem 0; border: 0; border-bottom: 1px solid var(--wp--preset--color--contrast); border-radius: 0;
	background: transparent; font: inherit; color: inherit;
}
.vv-form__field:focus { outline: none; border-bottom-color: var(--wp--preset--color--primary); box-shadow: 0 1px 0 var(--wp--preset--color--primary); }
textarea.vv-form__field { min-height: 8rem; resize: vertical; }
.vv-form__consent { display: flex; align-items: flex-start; gap: 0.75rem; margin: 0 0 1.75rem; font-size: var(--wp--preset--font-size--small); }
.vv-form__consent input { width: 1.1rem; height: 1.1rem; margin-top: 0.2rem; accent-color: var(--wp--preset--color--primary); }
.vv-form__submit {
	display: block; width: 100%; padding: 1.2rem 1rem; border: 0; cursor: pointer;
	background: var(--wp--preset--color--primary); color: var(--wp--preset--color--base);
	font: inherit; font-size: var(--wp--preset--font-size--x-small); font-weight: 400; letter-spacing: 0.06em; text-transform: uppercase;
	transition: background-color .2s ease;
}
.vv-form__submit:hover { background: var(--wp--preset--color--contrast); }
.vv-form__hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.vv-form__notice { margin: 0 0 1.5rem; padding: 0.9rem 1rem; font-size: var(--wp--preset--font-size--small); border-left: 3px solid var(--wp--preset--color--primary); background: var(--wp--preset--color--base); }
.vv-form__notice--error { border-left-color: #a33; }

/* ---------- Footer ---------- */
.vv-footer .vv-footer__nav { gap: 2.25rem; }
.vv-footer .vv-footer__nav a { font-size: var(--wp--preset--font-size--x-small); letter-spacing: 0.02em; text-transform: uppercase; text-decoration: none; color: var(--wp--preset--color--base); }
.vv-footer .vv-footer__nav a:hover { color: var(--wp--preset--color--gold); }
.vv-footer__rule { border: 0; border-top: 1px solid var(--vv-line-light); margin: 0; opacity: 1; }
.vv-footer__legal { margin: 0; font-size: var(--wp--preset--font-size--x-small); color: rgba(239, 238, 234, 0.62); line-height: 1.5; }
.vv-footer__legal-links { gap: 1.5rem; }
.vv-footer__legal-links p { margin: 0; font-size: var(--wp--preset--font-size--x-small); }
.vv-footer__legal-links a { color: rgba(239, 238, 234, 0.7); }
.vv-footer__legal-links a:hover { color: var(--wp--preset--color--base); }

@media (max-width: 781px) {
	.vv-footer .vv-footer__nav { flex-direction: column; align-items: flex-start; gap: 1rem; }
}

/* ---------- Pagine interne / articoli ---------- */
.vv-page-hero { position: relative; overflow: hidden; }
.vv-page-hero .wp-block-post-title { margin: 0; }
.vv-page-hero .wp-block-post-excerpt { margin: 1.25rem auto 0; max-width: 40rem; }
.vv-page-hero .wp-block-post-excerpt__more-link { display: none; }
.vv-meta { gap: 1rem; font-size: var(--wp--preset--font-size--x-small); letter-spacing: 0.04em; text-transform: uppercase; }
.vv-meta a { color: inherit; text-decoration: none; }
.vv-entry-content > * + * { margin-block-start: 1.5rem; }
.vv-entry-content h2, .vv-entry-content h3 { margin-block: 2.5rem 1rem; }
.vv-entry-content img { height: auto; }

.vv-post-card .wp-block-post-featured-image img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.vv-post-card .wp-block-post-title { margin: 0; font-size: var(--wp--preset--font-size--x-large); }
.vv-post-card .wp-block-post-title a { text-decoration: none; color: inherit; }
.wp-block-query-pagination { gap: 1.5rem; font-size: var(--wp--preset--font-size--x-small); letter-spacing: 0.04em; text-transform: uppercase; }
.wp-block-query-pagination a { color: inherit; text-decoration: none; }

/* ---------- Blocco campo ACF ---------- */
.vv-acf { margin-block: 2rem; }
.vv-acf__label {
	margin: 0 0 0.5rem; font-size: var(--wp--preset--font-size--x-small); font-weight: 400;
	letter-spacing: 0.04em; text-transform: uppercase; color: var(--wp--preset--color--gold-dark);
}
.vv-acf__value > :first-child { margin-top: 0; }
.vv-acf__value > :last-child { margin-bottom: 0; }
.vv-acf__value img { display: block; max-width: 100%; height: auto; }
.vv-acf__value ul { margin: 0; padding-left: 1.2rem; }
.vv-acf__value dl { margin: 0; display: grid; grid-template-columns: max-content 1fr; gap: 0.35rem 1.25rem; }
.vv-acf__value dt { font-weight: 400; }
.vv-acf__value dd { margin: 0; }

.vv-acf--box {
	padding: clamp(1.5rem, 3vw, 2.5rem);
	background: var(--wp--preset--color--surface);
	border-left: 3px solid var(--wp--preset--color--gold);
}
.vv-acf--box .vv-acf__value { font-size: var(--wp--preset--font-size--medium); }
.vv-acf--highlight {
	padding: clamp(1.5rem, 3vw, 2.5rem);
	background: var(--wp--preset--color--primary); color: var(--wp--preset--color--base);
}
.vv-acf--highlight .vv-acf__label { color: var(--wp--preset--color--gold); }
.vv-acf--highlight a { color: var(--wp--preset--color--base); }
.vv-acf--inline { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.5rem 1rem; margin-block: 1rem; }
.vv-acf--inline .vv-acf__label { margin: 0; }
.vv-acf--placeholder { opacity: .7; font-style: italic; border: 1px dashed var(--wp--preset--color--muted); padding: 1rem; }

/* ---------- Accessibilità ---------- */
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	* { transition: none !important; }
}
:focus-visible { outline: 2px solid var(--wp--preset--color--gold-dark); outline-offset: 3px; }
.has-primary-background-color :focus-visible { outline-color: var(--wp--preset--color--gold); }
