/*
Theme Name: Lemon.haus
Theme URI: https://lemon.haus
Author: Lemon.haus
Description: Tema de bloques de estilo Bauhaus para Lemon.haus: marketing y asesoría en IA. Todo el contenido se edita desde el editor de WordPress.
Version: 1.0.0
Requires at least: 6.6
Requires PHP: 8.1
License: GPL-2.0-or-later
Text Domain: lemon-haus
*/

/*
 * Estilos que theme.json no puede expresar: formas geométricas y detalles Bauhaus.
 * Colores y tipografía viven en theme.json; aquí solo se usan sus variables.
 */

:root {
	--lh-ink: var(--wp--preset--color--ink);
	--lh-lemon: var(--wp--preset--color--lemon);
	--lh-red: var(--wp--preset--color--red);
	--lh-blue: var(--wp--preset--color--blue);
	--lh-cream: var(--wp--preset--color--cream);
	--lh-paper: var(--wp--preset--color--paper);
	--lh-rule: 3px solid var(--lh-ink);
}

html { scroll-behavior: smooth; }
body { -webkit-font-smoothing: antialiased; }
:where(a, button, input, select, textarea, summary):focus-visible {
	outline: 3px solid var(--lh-blue);
	outline-offset: 3px;
}

/* ---------- Cabecera ---------- */
.lh-header {
	border-bottom: var(--lh-rule);
	position: sticky;
	top: 0;
	z-index: 50;
	background: var(--lh-cream);
}
.admin-bar .lh-header { top: var(--wp-admin--admin-bar--height, 32px); }

.lh-brand .wp-block-site-title { margin: 0; font-weight: 700; letter-spacing: -0.02em; font-size: 1.5rem; }
.lh-brand .wp-block-site-title a { text-decoration: none; }
.lh-brand { display: flex; align-items: center; gap: 0.75rem; }
.lh-brand::before {
	/* Marca: círculo limón, cuadrado rojo y triángulo azul */
	content: "";
	width: 60px;
	height: 18px;
	flex: none;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 18'%3E%3Ccircle cx='9' cy='9' r='9' fill='%23F6D312'/%3E%3Crect x='21' width='18' height='18' fill='%23E0301E'/%3E%3Cpath d='M51 0 60 18H42z' fill='%231F4E9C'/%3E%3C/svg%3E") no-repeat center / contain;
}
.lh-nav a { text-decoration: none; font-weight: 500; }
.lh-nav a:hover { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 6px; }

/* ---------- Secciones ---------- */
.lh-section { border-bottom: var(--lh-rule); }
.lh-eyebrow {
	text-transform: uppercase;
	letter-spacing: 0.14em;
	font-size: var(--wp--preset--font-size--small);
	font-weight: 600;
	display: inline-flex;
	align-items: center;
	gap: 0.6rem;
}
.lh-eyebrow::before {
	content: "";
	width: 12px;
	height: 12px;
	border-radius: 50%;
	background: var(--lh-red);
}

/* Hero */
.lh-hero h1 { margin-top: 0.4em; }
.lh-hero h1 em { font-style: normal; background: linear-gradient(transparent 62%, var(--lh-lemon) 62%); }
.lh-hero .wp-block-image img { width: 100%; height: auto; }

/* Botones */
.wp-block-button.is-style-outline .wp-block-button__link {
	border: var(--lh-rule);
	background: transparent;
	color: var(--lh-ink);
}
.wp-block-button.is-style-outline .wp-block-button__link:hover { background: var(--lh-ink); color: var(--lh-cream); }
.wp-block-button.lh-btn-lemon .wp-block-button__link { background: var(--lh-lemon); color: var(--lh-ink); }
.wp-block-button.lh-btn-lemon .wp-block-button__link:hover { background: var(--lh-ink); color: var(--lh-lemon); }

/* ---------- Tarjetas (servicios y blog) ---------- */
.lh-cards .wp-block-post-template { gap: 0; border-top: var(--lh-rule); border-left: var(--lh-rule); }
.lh-cards .wp-block-post {
	border-right: var(--lh-rule);
	border-bottom: var(--lh-rule);
	padding: clamp(1.5rem, 3vw, 2.5rem);
	background: var(--lh-paper);
	display: flex;
	flex-direction: column;
	gap: 1rem;
	transition: background-color 0.2s ease;
}
.lh-cards .wp-block-post:hover { background: var(--lh-cream); }
.lh-cards .wp-block-post-title { margin: 0; font-size: var(--wp--preset--font-size--large); }
.lh-cards .wp-block-post-title a { text-decoration: none; }
.lh-cards .wp-block-post-excerpt { margin: 0; flex: 1; }
.lh-cards .wp-block-post-excerpt__more-link,
.lh-cards .wp-block-read-more { font-weight: 600; }

/* Forma geométrica en cada servicio: rota entre círculo, cuadrado y triángulo */
.lh-services .wp-block-post::before {
	content: "";
	width: 56px;
	height: 56px;
	background: var(--lh-lemon);
	border-radius: 50%;
}
.lh-services .wp-block-post:nth-child(3n + 2)::before { background: var(--lh-red); border-radius: 0; }
.lh-services .wp-block-post:nth-child(3n + 3)::before {
	background: var(--lh-blue);
	border-radius: 0;
	clip-path: polygon(50% 0, 100% 100%, 0 100%);
}

.lh-cards .wp-block-post-date { font-size: var(--wp--preset--font-size--small); text-transform: uppercase; letter-spacing: 0.1em; }
.lh-cards .wp-block-post-featured-image { margin: calc(-1 * clamp(1.5rem, 3vw, 2.5rem)) calc(-1 * clamp(1.5rem, 3vw, 2.5rem)) 0; border-bottom: var(--lh-rule); }
.lh-cards .wp-block-post-featured-image img { aspect-ratio: 16 / 10; object-fit: cover; }

/* ---------- Proceso ---------- */
.lh-steps { gap: 0 !important; border: var(--lh-rule); }
.lh-steps > .wp-block-column { padding: clamp(1.5rem, 3vw, 2.5rem); margin: 0 !important; }
.lh-steps > .wp-block-column + .wp-block-column { border-left: var(--lh-rule); }
.lh-step-num { font-size: var(--wp--preset--font-size--x-large); font-weight: 800; line-height: 1; margin: 0; }
@media (max-width: 781px) {
	.lh-steps > .wp-block-column + .wp-block-column { border-left: 0; border-top: var(--lh-rule); }
}

/* ---------- Banda de llamada a la acción ---------- */
.lh-cta { position: relative; overflow: hidden; }
.lh-cta::after {
	content: "";
	position: absolute;
	left: -90px;
	bottom: -90px;
	width: 260px;
	height: 260px;
	border-radius: 50%;
	background: var(--lh-red);
	pointer-events: none;
}
.lh-cta > * { position: relative; z-index: 1; }

/* ---------- Formulario de contacto ---------- */
.lh-form { display: grid; gap: 1.1rem; max-width: 760px; }
.lh-form p { margin: 0; }
.lh-form .lh-row { display: grid; gap: 1.1rem; grid-template-columns: 1fr 1fr; }
@media (max-width: 640px) { .lh-form .lh-row { grid-template-columns: 1fr; } }
.lh-form label { display: block; font-weight: 600; margin-bottom: 0.35rem; }
.lh-form input[type="text"],
.lh-form input[type="email"],
.lh-form select,
.lh-form textarea {
	width: 100%;
	box-sizing: border-box;
	font: inherit;
	padding: 0.8rem 0.9rem;
	border: var(--lh-rule);
	border-radius: 0;
	background: var(--lh-paper);
	color: var(--lh-ink);
}
.lh-form textarea { min-height: 160px; resize: vertical; }
.lh-form .lh-consent { display: flex; gap: 0.6rem; align-items: flex-start; font-size: var(--wp--preset--font-size--small); }
.lh-form .lh-consent label { font-weight: 400; margin: 0; }
.lh-form .lh-consent input { width: 20px; height: 20px; margin-top: 0.15rem; accent-color: var(--lh-ink); flex: none; }
.lh-form .lh-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.lh-form button {
	justify-self: start;
	font: inherit;
	font-weight: 600;
	font-size: var(--wp--preset--font-size--small);
	text-transform: uppercase;
	letter-spacing: 0.08em;
	padding: 0.95em 1.7em;
	border: 0;
	background: var(--lh-ink);
	color: var(--lh-cream);
	cursor: pointer;
}
.lh-form button:hover { background: var(--lh-blue); color: var(--lh-paper); }
.lh-notice { padding: 1rem 1.2rem; border: var(--lh-rule); font-weight: 500; }
.lh-notice.is-ok { background: var(--lh-lemon); }
.lh-notice.is-error { background: var(--lh-paper); border-color: var(--lh-red); }

/* ---------- Pie ---------- */
.lh-footer { border-top: var(--lh-rule); }
.lh-footer a { color: inherit; }
.lh-footer .lh-brand::before { filter: none; }

/* ---------- Entradas ---------- */
.lh-article .wp-block-post-content > * + * { margin-top: 1.2em; }
.lh-article .wp-block-post-content h2 { font-size: var(--wp--preset--font-size--large); margin-top: 2em; }
.lh-article blockquote { border-left: 8px solid var(--lh-lemon); margin-left: 0; padding-left: 1.5rem; font-size: 1.3rem; }

.wp-block-query-pagination { font-weight: 600; }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	* { transition: none !important; }
}

.lh-plain-list { list-style: none; padding-left: 0; }
.lh-plain-list li + li { margin-top: 0.35rem; }
