/* Legalia v29: conversion redesign for the four priority PPC landings. */
:root{--lg-wa:#1fc867;--lg-wa-dark:#0c9f4a;--lg-ink:#07110e;--lg-gold:#d4af37;--lg-gold-soft:#f5e2a2}
body.lg-top-landing{padding-bottom:0}
body.lg-top-landing .site-header--ppc{min-height:70px;padding-top:10px;padding-bottom:10px}
body.lg-top-landing .site-header--ppc .brand{min-width:0}
body.lg-top-landing .site-header--ppc .header-actions{display:flex!important;margin-left:auto}
body.lg-top-landing .site-header--ppc .header-wa{display:inline-flex!important;background:linear-gradient(135deg,var(--lg-wa),var(--lg-wa-dark));border-color:rgba(255,255,255,.22);color:#fff!important;box-shadow:0 12px 30px rgba(31,200,103,.22)}
body.lg-top-landing .site-header--ppc .header-wa:before,.lg-wa-primary:before{content:"";width:20px;height:20px;flex:0 0 20px;background:url('/assets/img/whatsapp-icon-white.svg') center/contain no-repeat;margin-right:8px}
body.lg-top-landing .site-header--ppc .phone{display:inline-flex!important}

body.lg-top-landing .qh-hero,body.lg-top-landing .jp-hero{padding-top:70px;padding-bottom:64px}
body.lg-top-landing .qh-hero-grid,body.lg-top-landing .jp-hero-grid{align-items:center;gap:clamp(28px,4vw,52px)}
body.lg-top-landing .qh-hero h1,body.lg-top-landing .jp-hero h1{max-width:820px;font-size:clamp(43px,5.6vw,72px);line-height:.96;text-wrap:balance}
body.lg-top-landing .qh-lead,body.lg-top-landing .jp-lead{max-width:720px;font-size:clamp(17px,1.65vw,20px);line-height:1.55}
body.lg-top-landing .qh-actions,body.lg-top-landing .jp-actions,body.lg-top-landing .hero-actions{margin-top:24px;gap:11px}
body.lg-top-landing .lg-wa-primary{background:linear-gradient(135deg,var(--lg-wa),var(--lg-wa-dark))!important;color:#fff!important;border:1px solid rgba(255,255,255,.2)!important;box-shadow:0 16px 38px rgba(31,200,103,.25)!important}
body.lg-top-landing .lg-wa-primary:hover{box-shadow:0 20px 44px rgba(31,200,103,.34)!important}
body.lg-top-landing .lg-form-secondary{background:rgba(255,255,255,.07)!important;color:#fff!important;border:1px solid rgba(255,255,255,.17)!important;box-shadow:none!important}

.lg-hero-authority{display:flex;align-items:center;gap:12px;max-width:650px;margin-top:20px;padding:10px 13px 10px 10px;border:1px solid rgba(255,255,255,.13);border-radius:18px;background:rgba(3,10,8,.48);backdrop-filter:blur(12px);box-shadow:0 14px 40px rgba(0,0,0,.18)}
.lg-hero-authority img{width:48px;height:48px;flex:0 0 48px;border-radius:50%;object-fit:cover;object-position:50% 18%;border:2px solid rgba(245,226,162,.75);background:#fff}
.lg-hero-authority strong{display:block;color:#fff;font-size:14px;line-height:1.2}
.lg-hero-authority span{display:block;margin-top:3px;color:rgba(255,255,255,.72);font-size:12.5px;line-height:1.35}
.lg-hero-authority small{display:block;margin-top:3px;color:var(--lg-gold-soft);font-size:11.5px;font-weight:850}

/* White, easy-to-scan form card across the four pages. */
body.lg-top-landing .qh-hero-card,body.lg-top-landing .jp-hero-card,body.lg-top-landing .diagnostic-card{background:#fff!important;color:var(--lg-ink)!important;border:1px solid rgba(212,175,55,.34)!important;box-shadow:0 30px 90px rgba(0,0,0,.36)!important;backdrop-filter:none!important}
body.lg-top-landing .qh-hero-card h2,body.lg-top-landing .jp-hero-card h2,body.lg-top-landing .diagnostic-card .lg-visual-h2{color:var(--lg-ink)!important}
body.lg-top-landing .qh-hero-card>p,body.lg-top-landing .jp-hero-card>p,body.lg-top-landing .diagnostic-card>p{color:#53625d!important}
body.lg-top-landing .qh-hero-card .qh-form label,body.lg-top-landing .jp-hero-card .jp-form label,body.lg-top-landing .diagnostic-card .hero-mini-form label{color:#26332f!important}
body.lg-top-landing .qh-hero-card input,body.lg-top-landing .qh-hero-card select,body.lg-top-landing .qh-hero-card textarea,body.lg-top-landing .jp-hero-card input,body.lg-top-landing .jp-hero-card select,body.lg-top-landing .jp-hero-card textarea,body.lg-top-landing .diagnostic-card input[type="text"],body.lg-top-landing .diagnostic-card input[type="tel"]{background:#f5f7f6!important;color:#07110e!important;border-color:#d9e0dd!important}
body.lg-top-landing .qh-hero-card input::placeholder,body.lg-top-landing .jp-hero-card input::placeholder,body.lg-top-landing .diagnostic-card input::placeholder{color:#7b8984!important}
body.lg-top-landing .qh-hero-card .lg-privacy-consent,body.lg-top-landing .jp-hero-card .lg-privacy-consent,body.lg-top-landing .diagnostic-card .mini-consent{color:#53625d!important}
body.lg-top-landing .qh-hero-card .lg-privacy-consent a,body.lg-top-landing .jp-hero-card .lg-privacy-consent a,body.lg-top-landing .diagnostic-card .mini-consent a{color:#725b10!important}
body.lg-top-landing .qh-hero-card .qh-privacy,body.lg-top-landing .jp-hero-card .jp-privacy,body.lg-top-landing .diagnostic-card small{color:#64736e!important}
body.lg-top-landing .diagnostic-card .hero-mini-form{background:transparent!important;border:0!important;padding:0!important}
body.lg-top-landing .diagnostic-card .hero-mini-form-title{color:#07110e!important}
body.lg-top-landing .diagnostic-card .hero-fee-note{background:#f5f7f6!important;border-color:#d9e0dd!important;color:#26332f!important}
body.lg-top-landing .diagnostic-card .hero-fee-note strong{color:#725b10!important}
body.lg-top-landing .diagnostic-card .hero-fee-note span{color:#53625d!important}

/* Hoja-specific hero compaction. */
body.lg-top-hoja .hero{padding-top:64px!important;padding-bottom:58px!important}
body.lg-top-hoja .hero h1{font-size:clamp(43px,5.7vw,74px)!important;line-height:.95!important}
body.lg-top-hoja .lead{font-size:clamp(17px,1.7vw,20px)!important;line-height:1.55!important}
body.lg-top-hoja .hero-intent-strip{margin-top:20px!important}

/* One mobile CTA only. */
.lg-ppc-mobile-cta{display:none}
@media(max-width:980px){
  body.lg-top-landing{padding-bottom:78px}
  body.lg-top-landing .site-header--ppc{display:flex!important;flex-wrap:nowrap!important;min-height:64px!important;padding:9px 13px!important}
  body.lg-top-landing .site-header--ppc .brand{max-width:none!important;min-height:40px!important;padding:0 13px!important}
  body.lg-top-landing .site-header--ppc .brand-logo-img{width:92px!important;max-width:92px!important}
  body.lg-top-landing .site-header--ppc .header-actions{display:flex!important;width:auto!important;flex:0 0 auto!important;order:initial!important;padding:0!important;border:0!important;flex-direction:row!important}
  body.lg-top-landing .site-header--ppc .header-actions .phone{display:none!important}
  body.lg-top-landing .site-header--ppc .header-actions .header-wa{display:inline-flex!important;width:auto!important;min-height:42px!important;padding:9px 12px!important;font-size:12.5px!important;border-radius:999px!important}
  body.lg-top-landing .site-header--ppc .header-actions .header-wa:before{width:18px;height:18px;flex-basis:18px;margin-right:6px}
  body.lg-top-landing .qh-hero,body.lg-top-landing .jp-hero{padding-top:46px;padding-bottom:46px}
  body.lg-top-landing .qh-hero-grid,body.lg-top-landing .jp-hero-grid{grid-template-columns:1fr!important;gap:24px}
  body.lg-top-landing .qh-hero h1,body.lg-top-landing .jp-hero h1,body.lg-top-hoja .hero h1{font-size:clamp(36px,10.2vw,48px)!important;line-height:.98!important;letter-spacing:-.055em!important;margin-top:17px!important;margin-bottom:14px!important}
  body.lg-top-landing .qh-lead,body.lg-top-landing .jp-lead,body.lg-top-hoja .lead{font-size:16.5px!important;line-height:1.48!important}
  body.lg-top-landing .qh-actions,body.lg-top-landing .jp-actions,body.lg-top-landing .hero-actions{display:grid!important;grid-template-columns:1fr!important;margin-top:20px!important}
  body.lg-top-landing .qh-actions .qh-btn,body.lg-top-landing .jp-actions .jp-btn,body.lg-top-landing .hero-actions .btn{width:100%!important;min-height:52px!important}
  body.lg-top-landing .qh-trust,body.lg-top-landing .jp-trust{grid-template-columns:1fr!important;margin-top:18px!important}
  .lg-hero-authority{margin-top:16px;padding:9px 11px}
  .lg-hero-authority img{width:42px;height:42px;flex-basis:42px}
  body.lg-top-landing .qh-hero-card,body.lg-top-landing .jp-hero-card,body.lg-top-landing .diagnostic-card{border-radius:23px!important;padding:20px!important}
  .lg-ppc-mobile-cta{position:fixed;left:8px;right:8px;bottom:calc(env(safe-area-inset-bottom,0px) + 8px);z-index:100000;display:flex;align-items:center;justify-content:center;gap:9px;min-height:58px;padding:12px 16px;border-radius:18px;background:linear-gradient(135deg,var(--lg-wa),var(--lg-wa-dark));color:#fff!important;text-decoration:none;font-family:Inter,Arial,sans-serif;font-weight:950;font-size:15px;line-height:1.15;text-align:center;border:1px solid rgba(255,255,255,.32);box-shadow:0 18px 44px rgba(0,0,0,.34),0 0 0 5px rgba(31,200,103,.10)}
  .lg-ppc-mobile-cta:before{content:"";width:24px;height:24px;flex:0 0 24px;background:url('/assets/img/whatsapp-icon-white.svg') center/contain no-repeat}
  body.lg-top-landing .lg-floating-whatsapp-ainara{display:none!important}
  body.lg-top-landing .lg-mobile-sticky-contact{display:none!important}
}
@media(max-width:440px){
  body.lg-top-landing .qh-kicker,body.lg-top-landing .jp-kicker,body.lg-top-hoja .eyebrow{font-size:10.5px!important;letter-spacing:.08em!important}
  body.lg-top-landing .site-header--ppc .header-wa{font-size:0!important;padding:9px 11px!important}
  body.lg-top-landing .site-header--ppc .header-wa:before{margin-right:0}
  body.lg-top-hoja .hero-intent-strip{grid-template-columns:1fr!important}
}
body.lg-top-linea .qh-hero:before{background:linear-gradient(90deg,rgba(3,10,8,.98) 0%,rgba(3,10,8,.80) 50%,rgba(3,10,8,.72) 100%),url('/assets/img/mock-caso-servidumbre.webp') center/cover no-repeat!important}
body.lg-top-abogado .qh-hero:before{background:linear-gradient(90deg,rgba(3,10,8,.98) 0%,rgba(3,10,8,.82) 48%,rgba(3,10,8,.70) 100%),url('/assets/img/legalia-equipo-juridico-tecnico.webp') center/cover no-repeat!important}
body.lg-top-justiprecio .jp-hero:before{background:linear-gradient(90deg,rgba(3,10,8,.98) 0%,rgba(3,10,8,.80) 48%,rgba(3,10,8,.68) 100%),url('/assets/img/legalia-seccion-finca-justiprecio.webp') center/cover no-repeat!important}

/* Legalia v30: mobile PPC polish after real-device review. */
body.lg-top-landing .site-header--ppc .header-wa{display:none!important}
body.lg-top-landing .lg-wa-primary,
body.lg-top-landing a.lg-wa-primary,
body.lg-top-landing .hero-actions a.lg-wa-primary,
body.lg-top-landing .qh-actions a.lg-wa-primary,
body.lg-top-landing .jp-actions a.lg-wa-primary{
  background:#1fc867!important;
  background-image:linear-gradient(135deg,#25d366,#129c4b)!important;
  color:#fff!important;
  border-color:rgba(255,255,255,.28)!important;
}
body.lg-top-landing .lg-wa-primary:hover,
body.lg-top-landing .lg-wa-primary:focus-visible{
  background-image:linear-gradient(135deg,#2adf70,#0f9144)!important;
  color:#fff!important;
}
.lg-ppc-mobile-cta{opacity:0;visibility:hidden;transform:translateY(18px);pointer-events:none;transition:opacity .22s ease,transform .22s ease,visibility .22s ease}
.lg-ppc-mobile-cta.is-visible{opacity:1;visibility:visible;transform:translateY(0);pointer-events:auto}
@media(max-width:980px){
  body.lg-top-landing{padding-bottom:138px!important}
  body.lg-top-landing .site-header--ppc{justify-content:space-between!important}
  body.lg-top-landing .site-header--ppc .header-actions .phone{
    display:inline-flex!important;
    min-height:42px!important;
    padding:9px 12px!important;
    font-size:13px!important;
    border-radius:999px!important;
    white-space:nowrap!important;
  }
  body.lg-top-landing .site-header--ppc .header-actions .header-wa{display:none!important}
  body.lg-top-hoja .hero,
  body.lg-top-linea .qh-hero,
  body.lg-top-abogado .qh-hero,
  body.lg-top-justiprecio .jp-hero{
    padding-top:76px!important;
  }
  body.lg-top-landing .qh-kicker,
  body.lg-top-landing .jp-kicker,
  body.lg-top-hoja .eyebrow{
    margin-top:0!important;
    position:relative!important;
    z-index:2!important;
  }
}
@media(max-width:440px){
  body.lg-top-landing .site-header--ppc .brand{padding:0 8px!important}
  body.lg-top-landing .site-header--ppc .brand-logo-img{width:88px!important;max-width:88px!important}
  body.lg-top-landing .site-header--ppc .header-actions .phone{font-size:12px!important;padding:8px 10px!important}
  body.lg-top-hoja .hero,
  body.lg-top-linea .qh-hero,
  body.lg-top-abogado .qh-hero,
  body.lg-top-justiprecio .jp-hero{padding-top:82px!important}
}
