/* SOLVEXA · páginas de bloques sin plantilla propia (servicios, cómo funciona, campañas, blog, legales).
   Conservan su contenido; aquí reciben la tipografía, el ritmo, los botones y los márgenes del diseño nuevo. */

body:not(.page-template-solvexa-lienzo) {
  --wp--style--root--padding-left: var(--gutter);
  --wp--style--root--padding-right: var(--gutter);
  --wp--style--global--content-size: 760px;
  --wp--style--global--wide-size: 1180px;
}
body:not(.page-template-solvexa-lienzo) .wp-site-blocks > main:not(:has(#sxd)) { padding-top: clamp(40px, 6vw, 88px); padding-bottom: clamp(64px, 8vw, 112px); }

/* columna de lectura alineada a la izquierda, como el resto de la web */
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .is-layout-constrained > :where(:not(.alignleft):not(.alignright):not(.alignfull):not(.aligncenter)) { margin-left: 0 !important; }

/* ritmo vertical */
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-post-content > * + * { margin-block-start: 1.15em; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-post-content > :is(h2, h3) { margin-block-start: 2.2em; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-post-content > :is(h2, h3) + * { margin-block-start: .7em; }

/* títulos */
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) h1,
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-post-title {
  margin-bottom: .45em; max-width: 20ch;
  font: 700 clamp(40px, 5vw, 72px)/1.03 var(--f-display) !important; letter-spacing: -.015em; color: var(--marca); text-wrap: balance;
}
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) h2 { font: 700 clamp(28px, 3vw, 40px)/1.08 var(--f-display) !important; letter-spacing: -.01em; color: var(--marca); text-wrap: balance; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) h3 { font: 600 20px/1.3 var(--f-texto) !important; color: var(--tinta); }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) :is(h1, h2, h3, .wp-block-post-title) a { color: inherit; text-decoration: none; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) :is(h2, .wp-block-post-title) a:hover { text-decoration: underline; }

/* texto */
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) :is(p, li) { font-size: 17px; line-height: 1.6; color: var(--tinta-2); }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) :is(p, li) strong { color: var(--tinta); font-weight: 600; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) :is(p, li) a { color: var(--marca); font-weight: 500; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) :is(ul, ol).wp-block-list { padding-left: 1.2em; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-list li + li { margin-top: .45em; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-list li::marker { color: var(--acento); }

/* botones del sistema: el primero de cada grupo es el principal, el resto van en línea */
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-buttons { gap: 10px; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-button__link {
  display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: 0 22px !important;
  border: 1.5px solid var(--marca) !important; border-radius: 4px !important;
  background: var(--marca) !important; color: #fff !important;
  font: 600 16px/1.2 var(--f-texto) !important; text-decoration: none; box-shadow: none;
}
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-button__link:hover { background: var(--marca-hondo) !important; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-button + .wp-block-button .wp-block-button__link { background: transparent !important; color: var(--marca) !important; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-button + .wp-block-button .wp-block-button__link:hover { background: var(--marca) !important; color: #fff !important; }

/* portadas: las que solo eran un fondo decorativo sobran; las que llevan texto pasan a ser la banda de cierre */
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-cover:not(:has(h1, h2, h3, p, a)) { display: none; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-cover:has(h1, h2, h3, p, a) {
  min-height: 0 !important; margin-top: clamp(48px, 7vw, 96px); padding: clamp(40px, 6vw, 80px) var(--gutter);
  background: var(--marca); color: #fff; justify-content: flex-start; align-items: flex-start; text-align: left;
}
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-cover:has(h1, h2, h3, p, a) :is(.wp-block-cover__image-background, .wp-block-cover__background) { display: none; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-cover__inner-container { width: 100%; max-width: 760px; margin: 0; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-cover :is(h2, h3) { color: #fff !important; text-align: left; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-cover :is(p, li) { color: #D5E4F2 !important; text-align: left; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-cover .wp-block-buttons { justify-content: flex-start; margin-top: 1.4em; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-cover .wp-block-button__link { background: #fff !important; border-color: #fff !important; color: #004C7A !important; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-cover .wp-block-button + .wp-block-button .wp-block-button__link { background: transparent !important; color: #fff !important; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-cover .wp-block-button + .wp-block-button .wp-block-button__link:hover { background: #fff !important; color: #004C7A !important; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-spacer { display: none; }

/* desplegables como las preguntas frecuentes de la portada */
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-details { margin-block-start: 0 !important; padding: 0 !important; background: none !important; border: 0; border-bottom: 1px solid var(--linea); border-radius: 0 !important; box-shadow: none !important; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) :not(.wp-block-details) + .wp-block-details { margin-block-start: 1.2em !important; border-top: 1.5px solid var(--marca); }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-details summary { padding: 18px 36px 18px 0; position: relative; cursor: pointer; list-style: none; font: 600 18px/1.35 var(--f-texto); color: var(--tinta); }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-details summary::-webkit-details-marker { display: none; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-details summary::after { content: "+"; position: absolute; right: 4px; top: 50%; translate: 0 -50%; font: 700 26px/1 var(--f-display); color: var(--marca); }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-details[open] summary::after { content: "−"; }
body:not(.page-template-solvexa-lienzo) main:not(:has(#sxd)) .wp-block-details > :not(summary) { margin: 0 0 18px; }

/* blog */
body:not(.page-template-solvexa-lienzo) main .wp-block-post-date { font: 500 12px/1.4 var(--f-dato); letter-spacing: .06em; text-transform: uppercase; color: var(--tinta-3); }
body:not(.page-template-solvexa-lienzo) main .wp-block-post-featured-image img { border-radius: 4px; }
body:not(.page-template-solvexa-lienzo) main .wp-block-post-template > li + li { margin-top: clamp(48px, 6vw, 80px); padding-top: clamp(32px, 4vw, 56px); border-top: 1.5px solid var(--marca); }
body:not(.page-template-solvexa-lienzo) main .wp-block-post-template h2.wp-block-post-title { font-size: clamp(30px, 3.4vw, 46px) !important; max-width: 24ch; }
body.blog main h1, body.archive main h1 { margin-left: 0 !important; margin-right: auto !important; text-align: left; }

/* índice del blog: registro de entradas (fecha, título, resumen, enlace) */
body:is(.blog, .archive, .search) main:not(:has(#sxd)) .wp-block-post-template { list-style: none; margin: 0; padding: 0; max-width: 980px; border-top: 1.5px solid var(--marca); }
body:is(.blog, .archive, .search) main:not(:has(#sxd)) .wp-block-post-template > li,
body:is(.blog, .archive, .search) main:not(:has(#sxd)) .wp-block-post-template > li + li { margin: 0; padding: 0; border: 0; border-bottom: 1px solid var(--linea); }
body:is(.blog, .archive, .search) main:not(:has(#sxd)) .wp-block-post-template > li > .wp-block-group { display: flex; flex-direction: column; padding: clamp(24px, 3vw, 36px) var(--gutter) !important; }
body:is(.blog, .archive, .search) main:not(:has(#sxd)) .wp-block-post-template > li > .wp-block-group > * { margin: 0 !important; max-width: 760px; }
body:is(.blog, .archive, .search) main:not(:has(#sxd)) .wp-block-post-template .wp-block-post-date { order: -1; margin-bottom: 10px !important; }
body:is(.blog, .archive, .search) main:not(:has(#sxd)) .wp-block-post-template h2.wp-block-post-title { font-size: clamp(26px, 2.8vw, 36px) !important; line-height: 1.1 !important; max-width: 28ch; margin-bottom: 0; }
body:is(.blog, .archive, .search) main:not(:has(#sxd)) .wp-block-post-template .wp-block-post-featured-image { display: none; }
body:is(.blog, .archive, .search) main:not(:has(#sxd)) .sxr-resumen { margin-top: 12px !important; }
body:is(.blog, .archive, .search) main:not(:has(#sxd)) .sxr-resumen p { margin: 0 0 12px; max-width: 62ch; }
body:is(.blog, .archive, .search) main:not(:has(#sxd)) .sxr-leer { color: var(--marca); font-weight: 600; text-underline-offset: .22em; }
