/*
Theme Name: LL&HH Abogados
Theme URI: https://llhhabogados.com/
Author: Area23
Author URI: https://area23.es/
Description: Tema de bloques a medida para LL&HH Abogados (Luján Lago Abogados S.L.P.). Editable por completo desde el Editor del sitio: colores, tipografías, cabecera, pie, plantillas y patrones.
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 7.4
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: llhh
*/

/* ---------- Ajustes generales ---------- */
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }

:where(a, button, input, select, textarea, .wp-element-button):focus-visible {
	outline: 2px solid var(--wp--preset--color--acento);
	outline-offset: 3px;
	border-radius: 2px;
}

::selection { background: var(--wp--preset--color--acento-claro); color: var(--wp--preset--color--tinta); }

.screen-reader-text:focus { clip: auto; }

/* ---------- Cabecera ---------- */
.llhh-cabecera { position: sticky; top: 0; z-index: 50; }
.admin-bar .llhh-cabecera { top: 32px; }
@media (max-width: 782px) { .admin-bar .llhh-cabecera { top: 46px; } }
.llhh-cabecera .wp-block-site-logo img { height: auto; }
.llhh-cabecera .wp-block-navigation a:where(:not(.wp-element-button)) { text-decoration: none; }
.llhh-cabecera .wp-block-navigation .current-menu-item > a,
.llhh-cabecera .wp-block-navigation a[aria-current="page"] {
	text-decoration: underline;
	text-decoration-thickness: 2px;
	text-underline-offset: 0.45em;
}
@media (max-width: 600px) {
	.llhh-cabecera .llhh-boton-llamar { display: none; }
}

/* ---------- Motivo del monograma: barra vertical ---------- */
.is-style-barra {
	border-left: 4px solid var(--wp--preset--color--tinta);
	padding-left: 1.25rem;
}
.has-tinta-background-color .is-style-barra,
.is-style-barra.is-claro { border-left-color: var(--wp--preset--color--acento-claro); }

/* ---------- Franja de urgencia (detenidos 24 h) ---------- */
.llhh-telefono-gigante {
	font-variation-settings: "opsz" 72;
	line-height: 0.95 !important;
	letter-spacing: -0.02em;
	white-space: nowrap;
}
.llhh-telefono-gigante a { text-decoration: none; color: inherit; }
.llhh-telefono-gigante a:hover { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 0.12em; }

/* ---------- Listas de áreas ---------- */
.llhh-lista { list-style: none; padding-left: 0; }
.llhh-lista li { padding: 0.45rem 0; border-bottom: 1px solid var(--wp--preset--color--linea); }
.llhh-lista li:last-child { border-bottom: 0; }
.has-tinta-background-color .llhh-lista li { border-bottom-color: rgba(255,255,255,.18); }

/* ---------- Imágenes ---------- */
.llhh-foto img { width: 100%; height: 100%; object-fit: cover; }
.wp-block-post-featured-image img { object-fit: cover; }

/* ---------- Tarjetas del blog ---------- */
.llhh-entradas .wp-block-post { display: flex; flex-direction: column; }
.llhh-entradas .wp-block-post-title a { text-decoration: none; }
.llhh-entradas .wp-block-post-title a:hover { text-decoration: underline; }

/* ---------- Contenido de artículos ---------- */
.llhh-articulo p { hyphens: auto; }
.llhh-articulo figure.wp-block-image img { height: auto; }

/* ---------- Formulario de contacto (Contact Form 7) ---------- */
.wpcf7 form p { margin: 0 0 1.1rem; }
.wpcf7 label { display: block; font-weight: 600; font-size: 0.95rem; color: var(--wp--preset--color--tinta); }
.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 textarea,
.wpcf7 select {
	display: block;
	width: 100%;
	margin-top: 0.4rem;
	padding: 0.8rem 0.9rem;
	font: inherit;
	font-weight: 400;
	color: var(--wp--preset--color--texto);
	background: var(--wp--preset--color--blanco);
	border: 1px solid #b9c2ca;
	border-radius: 4px;
	box-sizing: border-box;
}
.wpcf7 textarea { min-height: 9rem; resize: vertical; }
.wpcf7 input:focus, .wpcf7 textarea:focus { border-color: var(--wp--preset--color--tinta); outline: 2px solid var(--wp--preset--color--acento-claro); outline-offset: 0; }
.wpcf7 .wpcf7-list-item { margin: 0; }
.wpcf7 .wpcf7-acceptance label { font-weight: 400; display: flex; gap: .6rem; align-items: flex-start; }
.wpcf7 .wpcf7-acceptance input { margin-top: .3rem; }
.wpcf7 input[type="submit"] {
	cursor: pointer;
	padding: 0.9rem 1.6rem;
	font: inherit;
	font-weight: 700;
	color: var(--wp--preset--color--blanco);
	background: var(--wp--preset--color--tinta);
	border: 0;
	border-radius: 4px;
}
.wpcf7 input[type="submit"]:hover { background: var(--wp--preset--color--acento); }
.wpcf7 .wpcf7-not-valid-tip { font-size: .9rem; margin-top: .3rem; }
.wpcf7 form .wpcf7-response-output { margin: 1rem 0 0; padding: .8rem 1rem; border-radius: 4px; }

/* ---------- Tablas (política de cookies) ---------- */
.wp-block-table table { border-collapse: collapse; width: 100%; font-size: .95rem; }
.wp-block-table td, .wp-block-table th { border: 1px solid var(--wp--preset--color--linea); padding: .6rem .75rem; vertical-align: top; }

/* ---------- Pie ---------- */
.llhh-pie a { text-decoration: none; }
.llhh-pie a:hover { text-decoration: underline; }

/* ---------- Sin huecos entre secciones a ancho completo ---------- */
.wp-site-blocks > * { margin-block-start: 0; }
.wp-block-post-content > .alignfull { margin-block-start: 0; margin-block-end: 0; }
.llhh-nowrap { white-space: nowrap; }

/* ---------- Botón flotante de WhatsApp ---------- */
.llhh-whatsapp {
	position: fixed;
	right: clamp(0.75rem, 2.5vw, 1.5rem);
	bottom: clamp(0.75rem, 2.5vw, 1.5rem);
	z-index: 90;
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.7rem 1.05rem 0.7rem 0.8rem;
	border-radius: 999px;
	background: #1f7a4d;
	color: #fff;
	font-weight: 700;
	font-size: 0.95rem;
	text-decoration: none;
	box-shadow: 0 6px 18px rgba(27, 42, 58, 0.28);
}
.llhh-whatsapp:hover, .llhh-whatsapp:focus-visible { background: #17643f; color: #fff; }
@media (max-width: 600px) {
	.llhh-whatsapp { padding: 0.8rem; }
	.llhh-whatsapp__texto { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}

/* ---------- Aviso de cookies ---------- */
.llhh-cookies {
	position: fixed;
	left: clamp(0.75rem, 2.5vw, 1.5rem);
	bottom: clamp(0.75rem, 2.5vw, 1.5rem);
	z-index: 100;
	max-width: 26rem;
	padding: 1.1rem 1.25rem;
	background: var(--wp--preset--color--blanco);
	color: var(--wp--preset--color--texto);
	border-left: 4px solid var(--wp--preset--color--tinta);
	border-radius: 4px;
	box-shadow: 0 10px 30px rgba(27, 42, 58, 0.25);
	font-size: 0.9rem;
	line-height: 1.5;
}
.llhh-cookies[hidden] { display: none; }
.llhh-cookies p { margin: 0 0 0.6rem; }
.llhh-cookies__titulo { font-family: var(--wp--preset--font-family--titulos); font-size: 1.2rem; color: var(--wp--preset--color--tinta); }
.llhh-cookies__botones { display: flex; gap: 0.6rem; flex-wrap: wrap; margin-top: 0.8rem; }
.llhh-cookies__boton {
	cursor: pointer;
	padding: 0.6rem 1.1rem;
	font: inherit;
	font-weight: 700;
	border-radius: 4px;
	border: 1px solid var(--wp--preset--color--tinta);
	background: var(--wp--preset--color--blanco);
	color: var(--wp--preset--color--tinta);
}
.llhh-cookies__boton--si { background: var(--wp--preset--color--tinta); color: var(--wp--preset--color--blanco); }
@media (max-width: 600px) {
	.llhh-cookies { right: 0.75rem; max-width: none; bottom: 5rem; }
}

/* ---------- Mapa con permiso ---------- */
.llhh-mapa {
	position: relative;
	aspect-ratio: 4 / 3;
	width: 100%;
	background: var(--wp--preset--color--granito);
	border-radius: 4px;
	overflow: hidden;
	display: grid;
	place-items: center;
	text-align: center;
}
.llhh-mapa iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.llhh-mapa__aviso { padding: 1.5rem; max-width: 22rem; }
.llhh-mapa__aviso p { margin: 0 0 0.75rem; }
.llhh-mapa__cargar {
	cursor: pointer;
	padding: 0.75rem 1.3rem;
	font: inherit;
	font-weight: 700;
	border: 0;
	border-radius: 4px;
	background: var(--wp--preset--color--tinta);
	color: var(--wp--preset--color--blanco);
}
.llhh-mapa__cargar:hover { background: var(--wp--preset--color--acento); }

/* ---------- Fichas del equipo y de medios ---------- */
.llhh-perfil img { aspect-ratio: 4 / 5; object-fit: cover; width: 100%; }
.llhh-pendiente { color: var(--wp--preset--color--gris); font-style: italic; }
