/* Video di Instagram con anteprima nostra (shortcode [video_instagram], mercato/inc/video-instagram.php). */

.mercato-video-ig {
	max-width: 340px;
	margin: 0 auto;
}

.mercato-video-ig__riquadro {
	position: relative;
	aspect-ratio: 9 / 16;
	overflow: hidden;
	border-radius: 14px;
	background: #2b2420;
	box-shadow: 0 12px 32px rgba(70, 35, 25, .18);
}

.mercato-video-ig__anteprima {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.mercato-video-ig__guarda {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 14px;
	width: 100%;
	padding: 0;
	border: 0;
	background: rgba(30, 15, 10, .18);
	cursor: pointer;
}

.mercato-video-ig__play {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 88px;
	height: 88px;
	border-radius: 50%;
	background: #95405a;
	color: #fff;
}
.mercato-video-ig__play svg { width: 40px; height: 40px; margin-left: 5px; fill: currentColor; }

.mercato-video-ig__etichetta {
	padding: .55em 1.2em;
	border-radius: 6px;
	background: #95405a;
	color: #fff;
	font-weight: 700;
	font-size: 1rem;
	letter-spacing: .02em;
}

.mercato-video-ig__guarda:hover .mercato-video-ig__play,
.mercato-video-ig__guarda:hover .mercato-video-ig__etichetta,
.mercato-video-ig__guarda:focus-visible .mercato-video-ig__play,
.mercato-video-ig__guarda:focus-visible .mercato-video-ig__etichetta { background: #7a3349; }
.mercato-video-ig__guarda:focus-visible { outline: 3px solid #fff; outline-offset: -6px; }

.mercato-video-ig__nota {
	margin-top: .8rem;
	font-size: .85rem;
	line-height: 1.45;
	text-align: center;
	color: #6b5d52;
}
.mercato-video-ig__nota a { color: inherit; }

/* Video caricato: lascia lo spazio alla finestra di Instagram, che si dà da sola l'altezza. */
.mercato-video-ig.is-caricato .mercato-video-ig__riquadro {
	aspect-ratio: auto;
	overflow: visible;
	border-radius: 0;
	background: none;
	box-shadow: none;
}
.mercato-video-ig.is-caricato .instagram-media { margin: 0 auto !important; min-width: 0 !important; }

/* Pagina prenotazione tavolo: testo accanto al video su schermi larghi, uno sotto l'altro sul telefono. */
.wp-block-columns.mercato-testo-e-video {
	max-width: 1080px;
	margin: 2.5rem auto 3.5rem;
	gap: 3.5rem;
	align-items: center;
}
.mercato-testo-e-video .mercato-testo-e-video__domanda {
	margin: 2.2rem 0 1.2rem;
	font-size: clamp(1.35rem, 1.1rem + 1vw, 1.75rem);
	line-height: 1.3;
}
.mercato-testo-e-video .mercato-testo-e-video__azione .wp-block-button { flex: 0 0 auto; width: auto; }
.mercato-testo-e-video .mercato-testo-e-video__azione .wp-block-button__link {
	display: inline-block;
	width: auto;
	padding: .8em 1.6em;
	border-radius: 6px;
	font-size: 1.15rem;
	font-weight: 700;
}
@media (min-width: 782px) {
	.wp-block-columns.mercato-testo-e-video { margin-top: 3.5rem; }
	.mercato-testo-e-video .mercato-testo-e-video__testo p { text-align: left; }
}
@media (max-width: 781px) {
	.mercato-testo-e-video .mercato-testo-e-video__testo,
	.mercato-testo-e-video .mercato-testo-e-video__domanda { text-align: center; }
	.mercato-testo-e-video .mercato-testo-e-video__azione { justify-content: center; }
}

/* Pagina prenotazione tavolo: galleria e WhatsApp nello stesso stile del riquadro del video. */
.wp-block-gallery.mercato-tavolo-galleria {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 20px;
	max-width: 1080px;
	margin: 1rem auto 4rem;
}
.wp-block-gallery.mercato-tavolo-galleria figure.wp-block-image:not(#individual-image) {
	width: 100% !important;
	margin: 0;
	aspect-ratio: 4 / 5;
	overflow: hidden;
	border-radius: 14px;
	box-shadow: 0 12px 32px rgba(70, 35, 25, .14);
}
.wp-block-gallery.mercato-tavolo-galleria figure.wp-block-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.wp-block-columns.mercato-whatsapp {
	max-width: 1080px;
	margin: 0 auto 1.5rem;
	padding: 2.5rem 3rem;
	gap: 3rem;
	border-radius: 14px;
	background: #f5e3c8;
}
.mercato-whatsapp h2 { margin: 0 0 .8rem; font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem); }
.mercato-whatsapp p { margin: 0 0 1.4rem; }
.mercato-whatsapp .mercato-whatsapp__azione .wp-block-button { flex: 0 0 auto; width: auto; }
.mercato-whatsapp .mercato-whatsapp__azione .wp-block-button__link {
	display: inline-block;
	width: auto;
	padding: .8em 1.6em;
	border-radius: 6px;
	font-size: 1.15rem;
	font-weight: 700;
}
.mercato-whatsapp .mercato-whatsapp__qr-nota { margin: 1rem 0 0; font-size: .9rem; color: #6b5d52; }
/* L'immagine ha angoli arrotondati su fondo bianco (raggio ~6,5% della larghezza): un raggio un po' più grande li copre. */
.mercato-whatsapp__qr figure.wp-block-image img { display: block; width: 100%; border-radius: 8%; }

@media (max-width: 781px) {
	.wp-block-gallery.mercato-tavolo-galleria { gap: 8px; margin-bottom: 2.5rem; }
	.wp-block-gallery.mercato-tavolo-galleria figure.wp-block-image:not(#individual-image) { border-radius: 10px; box-shadow: none; }
	.wp-block-columns.mercato-whatsapp { padding: 2rem 1.4rem; text-align: center; }
	.mercato-whatsapp .mercato-whatsapp__azione { justify-content: center; }
	/* Sul telefono il QR non serve: si tocca il pulsante. */
	.mercato-whatsapp__qr, .mercato-whatsapp .mercato-whatsapp__qr-nota { display: none; }
}
