/*
 * Samay · páginas hechas con Elementor.
 * Los widgets de Elementor usan otro HTML que los bloques: estas reglas les dan el mismo aspecto
 * que el tema (style.css + theme.json). Lo que cambies en el panel de Elementor tiene prioridad.
 */

/* ---------- Títulos ---------- */
/* Elementor fuerza line-height:1; el tema usa 1.15 (theme.json → elements.heading). */
.elementor .elementor-widget-heading .elementor-heading-title { line-height: 1.15; }
/* Las clases de color y tamaño de la paleta quedan en el widget: el título las hereda. */
.elementor .elementor-widget-heading.has-text-color .elementor-heading-title { color: inherit; }
.elementor .elementor-widget-heading[class*="-font-size"] .elementor-heading-title { font-size: inherit; }

/* Texto coloreado con la barra de formato de WordPress (<mark class="has-inline-color">): solo color, sin resaltado. */
.elementor mark.has-inline-color { background: transparent; }

/* ---------- Textos ---------- */
.elementor .elementor-widget-text-editor :where(p, ul, ol, blockquote) { margin-block: 0; }
.elementor .elementor-widget-text-editor :where(p, ul, ol) + :where(p, ul, ol) { margin-block-start: 1em; }

/* HTML (iconos, hojas…): con bloques su margen se solapa con la separación; en Elementor se sumaría. */
.elementor .elementor-widget-html :where(.samay-icono, .samay-hoja, .samay-comillas, p, div):first-child { margin-block-start: 0; }
.elementor .elementor-widget-html :where(.samay-icono, .samay-hoja, .samay-comillas, p, div):last-child { margin-block-end: 0; }

/* ---------- Botones (como theme.json → elements.button) ---------- */
.elementor .elementor-widget-button .elementor-button {
	background-color: var(--wp--preset--color--coral);
	color: var(--wp--preset--color--tinta);
	border-radius: 40px;
	padding: .85rem 1.7rem;
	font-family: var(--wp--preset--font-family--texto);
	font-weight: 700;
	font-size: .95rem;
	line-height: inherit;
	transition: background-color .2s, transform .2s, color .2s;
}
.elementor .elementor-widget-button .elementor-button:hover,
.elementor .elementor-widget-button .elementor-button:focus-visible {
	background-color: #F5B696;
	color: var(--wp--preset--color--tinta);
	transform: translateY(-2px);
}
.elementor .elementor-widget-button.is-style-outline .elementor-button {
	border: 1.5px solid #DCD4D0;
	background: transparent;
	padding: calc(.85rem - 1.5px) calc(1.7rem - 1.5px);
}
.elementor .elementor-widget-button.is-style-outline .elementor-button:hover {
	border-color: var(--wp--preset--color--coral);
	background: var(--wp--preset--color--coral-fondo);
}
.elementor .samay-chips .elementor-button { padding: .45rem 1rem !important; font-size: .85rem; font-weight: 600; background: var(--wp--preset--color--blanco) !important; }
.elementor .samay-chips .elementor-button:hover { transform: none; }

/* ---------- Imágenes ---------- */
/* theme.json → blocks.core/image: esquinas de 22px */
.elementor .elementor-widget-image img { border-radius: 22px; }
.elementor-widget-image.is-style-organica img {
	border-radius: 38% 42% 44% 40% / 46% 42% 46% 42% !important;
	aspect-ratio: 1 / .8; object-fit: cover; width: 100%;
	box-shadow: 0 18px 45px rgba(142,118,179,.14);
}
.elementor-widget-image.is-style-sombra img { box-shadow: 0 18px 45px rgba(142,118,179,.14); }
.samay-galeria .elementor-widget-image img { aspect-ratio: 1 / 1; object-fit: cover; width: 100%; }
.samay-galeria .elementor-widget-image .widget-image-caption { font-weight: 600; color: var(--wp--preset--color--tinta); text-align: left; }
.samay-taller-imagen.elementor-widget-image img, .samay-entrada-imagen.elementor-widget-image img { aspect-ratio: 16/9; object-fit: cover; width: 100%; border-radius: 22px; }
.samay-retrato.elementor-widget-image img { aspect-ratio: 1/1; object-fit: cover; width: 100%; border-radius: 50%; }

/* Tarjetas de sala: foto arriba a sangre (style.css ya da margen al resto con .samay-sala > :not(.wp-block-image)) */
.samay-sala .elementor-widget-image img { border-radius: 0; aspect-ratio: 4/3; object-fit: cover; width: 100%; }
.samay-sala > .elementor-widget-image, .samay-sala > .e-con-inner > .elementor-widget-image { padding-inline: 0; }

/* ---------- Secciones del diseño ---------- */
.samay-pasos > .e-con, .samay-pasos > .e-con-inner > .e-con { position: relative; z-index: 1; }
/* Elementor usa ::before de los contenedores para su capa de fondo (width/height 100%): la línea del tema necesita los suyos. */
.e-con.samay-pasos::before { width: auto; height: 0; bottom: auto; opacity: 1; mix-blend-mode: normal; border-radius: 0; }
.samay-fondo-coral-morado .samay-etiqueta { background: rgba(255,255,255,.65); }

@media (max-width: 767px) {
	.samay-pasos::before { display: none; }
	.samay-cta-derecha { text-align: left !important; }
	/* Elementor fija la alineación de cada contenedor en su propio CSS: aquí solo se cambia en móvil. */
	.elementor .samay-cta-derecha .e-con { --justify-content: flex-start !important; }
	.samay-cta-derecha .samay-contacto-linea { justify-content: flex-start !important; }
}
