/* Integración WordPress/Divi. Mantiene el nuevo sistema aislado en .csp-system. */
body.csp-system {
  width: 100%;
  min-width: 0;
  background: var(--paper);
  color: var(--ink);
}

body.csp-system a:where(:not(.button)) { color: inherit; }
body.csp-system h1,
body.csp-system h2,
body.csp-system h3,
body.csp-system h4 { color: inherit; }

body.csp-system.admin-bar .site-header { top: 32px; }
body.csp-system .site-header,
body.csp-system .blog-nav,
body.csp-system main,
body.csp-system .footer { isolation: isolate; }

body.csp-system main { min-height: 60vh; scroll-margin-top: 112px; }
body.csp-system .screen-reader-text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

body.csp-system .summary > p {
  max-width: 72ch;
  margin: 0;
  font-size: 1.08rem;
}

body.csp-system .article-copy > :first-child { margin-top: 0; }
body.csp-system .article-copy iframe,
body.csp-system .article-copy video,
body.csp-system .article-copy img { max-width: 100%; height: auto; }

body.csp-system .article-copy,
body.csp-system .article-layout,
body.csp-system .footer,
body.csp-system .footer__brand { min-width: 0; }

body.csp-system .table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  -webkit-overflow-scrolling: touch;
}

body.csp-system .table-wrap > table { min-width: max-content; }

body.csp-system .history-notice {
  display: block;
}

body.csp-system .csp-demo-form.is-confirmed .form-note {
  color: var(--terracotta);
  font-weight: 600;
}

body.csp-system .archive .clear-button {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

body.csp-system .empty-state { display: block; }

body.csp-system .article-copy h2,
body.csp-system .article-copy h3 { scroll-margin-top: 150px; }

@media (max-width: 782px) {
  body.csp-system.admin-bar .site-header { top: 46px; }
}

@media (max-width: 600px) {
  body.csp-system.admin-bar .site-header { top: 0; }

  body.csp-system .wordmark--footer {
    width: 100%;
    max-width: 100%;
  }

  body.csp-system .wordmark--footer .wordmark__full {
    width: 100%;
    min-width: 0;
    gap: .35rem;
    font-size: 12px;
    letter-spacing: .08em;
  }

  body.csp-system .footer__brand a { overflow-wrap: anywhere; }
}
body.csp-system .article-header,
body.csp-system .article-header > * {
  min-width: 0;
}

body.csp-system .article-header h1,
body.csp-system .article-deck,
body.csp-system .summary p,
body.csp-system .article-copy {
  overflow-wrap: anywhere;
}

body.csp-system .article-copy .table-wrap {
  overflow-wrap: normal;
}

@media (max-width: 960px) {
  body.csp-system .article-header {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Home only: keep the dark CTA readable despite .contact-direct a inheritance. */
body.csp-home .contact-direct a.button--dark {
  color: var(--paper);
}

/* Small guide copy needs at least 4.5:1 against the sand panel. */
body.csp-home .focus--guide > p:not(.eyebrow) {
  color: #57514b;
}

/* Decisiones visuales aprobadas 2026-10-22. Alcance: sistema ES. */
body.csp-system { --csp-ink:#1C1A18; --csp-paper:#F2EFE9; --csp-terra:#9D4F34; }
body.csp-system .site-header { position:sticky; top:0; z-index:100; }
body.csp-system .blog-nav { position:relative; top:auto; }
body.csp-article .article-copy,
body.csp-article .article-copy :is(p,li,blockquote,td,th) { font-family:"Source Serif 4",Georgia,serif; }

/* Conjunto Divi compartido: piloto privado y Publicaciones ES. */
body.csp-divi-shell #page-container{padding-top:0!important}body.csp-divi-shell .et-l--header{position:sticky;top:0;z-index:100;background:#f2efe9}body.csp-divi-shell.admin-bar .et-l--header{top:32px}body.csp-divi-shell .csp-pilot-header,body.csp-divi-shell .csp-pilot-footer{padding:0;background:var(--paper)}body.csp-divi-shell .csp-pilot-header-row{display:flex;align-items:center;justify-content:space-between;gap:24px;width:100%;max-width:1440px;padding:14px var(--pad);margin:auto}body.csp-divi-shell .csp-pilot-header-row .et_pb_column{margin:0;width:auto;float:none}body.csp-divi-shell .et_pb_text{margin-bottom:0}body.csp-divi-shell .csp-pilot-header-row .et_pb_text_inner p{padding:0}body.csp-divi-shell .pilot-desktop-nav{display:flex;align-items:center;gap:22px;font:540 13px/1.4 var(--sans)}body.csp-divi-shell .pilot-desktop-nav a{white-space:nowrap;color:var(--ink)}body.csp-divi-shell .pilot-desktop-nav a:last-child{background:var(--ink);color:var(--paper);padding:12px 16px}body.csp-divi-shell .pilot-mobile-menu{display:none}body.csp-divi-shell .csp-pilot-body,body.csp-divi-shell .csp-pilot-body .et_pb_row,body.csp-divi-shell .csp-pilot-content{padding:0;margin:0;width:100%;max-width:none}body.csp-divi-shell .csp-pilot-content .et_pb_text_inner{font:inherit}body.csp-divi-shell .csp-pilot-footer-row{display:grid;grid-template-columns:1.4fr repeat(4,.8fr);gap:32px;width:100%;max-width:1440px;padding:48px var(--pad);margin:auto;border-top:1px solid var(--line)}body.csp-divi-shell .csp-pilot-footer-row .et_pb_column{width:auto!important;float:none;margin:0!important;min-width:0}body.csp-divi-shell .pilot-footer-nav a{display:block;padding:5px 0;color:var(--ink);font:400 13px/1.5 var(--sans)}body.csp-divi-shell .pilot-footer-nav strong{font:600 11px/1.4 var(--sans);text-transform:uppercase;letter-spacing:.08em}body.csp-divi-shell .pilot-footer-brand p{font:400 13px/1.6 var(--sans);padding-top:16px}body.csp-divi-shell .csp-pilot-legal{width:100%;max-width:1440px;margin:auto;padding:0 var(--pad) 24px;font:400 12px/1.5 var(--sans)}body.csp-divi-shell a:focus-visible,body.csp-divi-shell summary:focus-visible{outline:2px solid var(--ink);outline-offset:4px}body.csp-divi-shell main:focus{outline:none}body.csp-divi-shell{scroll-padding-top:112px}body.csp-divi-shell main{scroll-margin-top:112px}@media(max-width:1100px){body.csp-divi-shell .pilot-desktop-nav{gap:12px;font-size:12px}}@media(max-width:1020px){body.csp-divi-shell .pilot-desktop-nav{display:none}body.csp-divi-shell .pilot-mobile-menu{display:block}body.csp-divi-shell .pilot-mobile-menu summary{display:grid;place-items:center;min-width:64px;min-height:44px;border:1px solid var(--ink);cursor:pointer;font:600 13px/1 var(--sans)}body.csp-divi-shell .pilot-mobile-menu nav{position:absolute;top:100%;left:0;right:0;background:var(--paper);padding:16px var(--pad);border-bottom:1px solid var(--line);max-height:70vh;overflow:auto}body.csp-divi-shell .pilot-mobile-menu nav a{display:block;padding:16px 0;border-bottom:1px solid var(--line);font:500 16px/1.4 var(--sans)}body.csp-divi-shell .csp-pilot-header-row{width:100%!important;display:flex!important}body.csp-divi-shell .csp-pilot-header-row .et_pb_column{margin:0!important;width:auto!important}body.csp-divi-shell .csp-pilot-footer-row{grid-template-columns:1fr 1fr}body.csp-divi-shell .pilot-footer-brand{grid-column:1/-1}}@media(max-width:782px){body.csp-divi-shell.admin-bar .et-l--header{top:46px}}@media(max-width:600px){body.csp-divi-shell.admin-bar .et-l--header{top:0}}body.csp-divi-shell .csp-pilot-header-row:after,body.csp-divi-shell .csp-pilot-footer-row:after{display:none}body.csp-divi-shell .csp-pilot-header-row{min-height:76px}@media(max-width:1020px){body.csp-divi-shell .pilot-mobile-menu nav{position:fixed;top:108px;left:0;right:0;width:100vw;box-sizing:border-box;max-width:100%;max-height:calc(100dvh - 108px)}}@media(max-width:782px){body.csp-divi-shell .pilot-mobile-menu nav{top:122px;max-height:calc(100dvh - 122px)}}@media(max-width:600px){body.csp-divi-shell .pilot-mobile-menu nav{top:76px;max-height:calc(100dvh - 76px)}}body.csp-divi-shell .csp-pilot-footer{background:var(--ink);color:var(--paper)}body.csp-divi-shell .csp-pilot-footer .wordmark,body.csp-divi-shell .pilot-footer-nav a{color:var(--paper)}body.csp-divi-shell .csp-pilot-footer a:focus-visible{outline-color:var(--paper)}body.csp-divi-shell .csp-pilot-footer .wordmark__ampersand{filter:brightness(0) invert(1)}@media(max-width:1020px){body.csp-divi-shell .csp-pilot-header-row{min-height:71px;padding-top:12px;padding-bottom:12px}body.csp-divi-shell .pilot-mobile-menu summary{width:44px;min-width:44px;height:44px;box-sizing:border-box;list-style:none}body.csp-divi-shell .pilot-mobile-menu summary::-webkit-details-marker{display:none}body.csp-divi-shell .pilot-mobile-menu nav{top:103px;max-height:calc(100dvh - 103px)}}@media(max-width:782px){body.csp-divi-shell .pilot-mobile-menu nav{top:117px;max-height:calc(100dvh - 117px)}}@media(max-width:600px){body.csp-divi-shell .pilot-mobile-menu nav{top:71px;max-height:calc(100dvh - 71px)}}@media(max-width:1020px){body.csp-divi-shell .csp-pilot-footer-row>.et_pb_column:first-child{grid-column:1/-1}}body.csp-divi-shell .csp-pilot-footer .wordmark__full{display:flex;font-size:10px;gap:.35rem;letter-spacing:.08em}body.csp-divi-shell .csp-pilot-footer .wordmark__compact{display:none}

body.csp-divi-shell .csp-pilot-header-row{min-height:77px}
body.csp-divi-shell .pilot-desktop-nav a:last-child{background:transparent;color:var(--ink);border:1px solid var(--ink);min-height:44px;display:inline-flex;align-items:center}
body.csp-divi-shell .csp-pilot-footer .wordmark__full{font-size:12px}
@media(max-width:1020px){body.csp-divi-shell .csp-pilot-header-row{min-height:71px}body.csp-divi-shell .csp-pilot-footer .wordmark__full{font-size:12px}}
body.csp-publicaciones .ph,body.csp-publicaciones .pub-body{--carbon:#1C1A18;--piedra:#F2EFE9;--terra:#9D4F34;background:var(--paper)}
body.csp-publicaciones .ph h1{font-weight:430}

/* El cuerpo Divi ya incluye su propio ancho y espaciado. */
body.csp-publicaciones #main-content,body.csp-publicaciones .et-l--post .et_pb_section{background:var(--paper)}
body.csp-publicaciones .et-l--post .et_pb_section{padding:0}
body.csp-publicaciones .et-l--post .et_pb_row{width:100%;max-width:1440px;padding:0;margin:0 auto}

/* Menú compartido: desplazamiento explícito con/sin barra administrativa. */
body.csp-divi-shell .pilot-desktop-nav a[aria-current="page"],
body.csp-divi-shell .pilot-mobile-menu nav a[aria-current="page"] {
  text-decoration: underline;
  text-underline-offset: .3em;
  text-decoration-thickness: 1px;
}
@media (max-width:1020px) {
  body.csp-divi-shell { --csp-shell-height:71px; --csp-shell-admin-offset:0px; }
  body.csp-divi-shell.admin-bar { --csp-shell-admin-offset:32px; }
  body.csp-divi-shell .pilot-mobile-menu nav {
    top:calc(var(--csp-shell-height) + var(--csp-shell-admin-offset));
    max-height:calc(100dvh - var(--csp-shell-height) - var(--csp-shell-admin-offset));
  }
}
@media (max-width:782px) {
  body.csp-divi-shell.admin-bar { --csp-shell-admin-offset:46px; }
}
@media (max-width:600px) {
  body.csp-divi-shell.admin-bar { --csp-shell-admin-offset:0px; }
}

/* Narrow hub links must reflow rather than disappear under the main clipping. */
@media(max-width:360px){
  body.csp-hub .hub-journal .hub-section-intro{min-width:0}
  body.csp-hub .hub-journal .text-link{display:block;white-space:normal;max-width:100%;overflow-wrap:break-word;width:fit-content}
}
body.csp-404 .csp-error-page{max-width:960px;margin:auto;padding:clamp(4rem,9vw,8rem) var(--pad)}
body.csp-404 .csp-error-page h1{font:500 clamp(36px,5vw,64px)/1.12 var(--sans);margin:1rem 0 1.5rem}
body.csp-404 .csp-error-page>p:not(.eyebrow){font:400 20px/1.6 var(--serif);max-width:42rem}
body.csp-404 .csp-error-page nav{display:flex;flex-wrap:wrap;gap:1rem;margin-top:2rem}
body.csp-404 .csp-error-page .button{white-space:normal;max-width:100%}

/* The native home body contains a floated Divi column: keep it in the flow. */
body.csp-home.csp-divi-shell .et-l--post{display:flow-root}

/* Contact validation: scoped to the current Spanish template. */
body.csp-contacto .field-error{color:#833b28;font:500 14px/1.5 "Archivo",sans-serif;margin:8px 0 0;}
body.csp-contacto .inquiry-form [aria-invalid="true"]:is(input,textarea){border:2px solid #833b28;}
body.csp-contacto .form-notice p{margin:0;}
body.csp-contacto .form-notice ul{margin:12px 0 0;padding-left:22px;}
body.csp-contacto .form-notice a{text-decoration:underline;}
body.csp-contacto .inquiry-form .field-error{grid-column:1/-1;}


/* CSP cierre visual 2026-10-23. Diseño aprobado por Mario: D1–D5. */
body.csp-system{--csp-h1-tracking:-.03em;--csp-h2-tracking:-.025em;--csp-muted-accessible:#68625B;--csp-accent-quote:#9D4F34}
@media(max-width:760px){body.csp-home .hero{background:none}}
body.csp-firma main blockquote{border-left-color:var(--csp-accent-quote)}
body.csp-publicaciones .pub-head .ct,body.csp-publicaciones .pub-cross p{color:var(--csp-muted-accessible)}
body.csp-system:not(.error404) main h2{letter-spacing:var(--csp-h2-tracking)}
@media(min-width:481px){body.csp-system:not(.error404) main h1{letter-spacing:var(--csp-h1-tracking)}}
@media(max-width:480px){body.csp-system:not(.error404) main h1{word-spacing:.1em}}
/* Service titles stay in their original mobile tracking through the existing 600px font breakpoint. */
@media(min-width:481px) and (max-width:600px){body.csp-system.csp-service main h1{letter-spacing:-.065em;word-spacing:.1em}}
/* The shared layouts and Publications have inline sizes: only their measured small classes. */
body.csp-system :is(.pilot-footer-nav strong,.eb,.go){font-size:12px}
body.csp-system :is(.pilot-desktop-nav a,.csp-pilot-legal,.csp-pilot-legal p,.pub-head .ct){font-size:13px}

/* CSP QA 2026-10-23: dual-tone keyboard focus over light and dark main surfaces. */
body.csp-divi-shell main a:focus-visible{box-shadow:0 0 0 4px var(--paper)}

/* Mario 2026-10-23: terracotta identity accent on the dark ES footer. */
body.csp-system.csp-divi-shell .csp-pilot-footer .wordmark__ampersand{filter:none;background-color:#C0785B}


/* Mario 2026-10-23: ES Blog label floor and shared desktop hover. */
html[lang^="es"] body.csp-system.csp-article .article-header .article-mode::after{font-size:12px!important;line-height:1.3!important}
@media(hover:hover){
html[lang^="es"] body.csp-system.csp-divi-shell .pilot-desktop-nav a:not(:last-child):hover{text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:.3em}
html[lang^="es"] body.csp-system.csp-divi-shell .pilot-desktop-nav a:last-child:hover{background-color:var(--terracotta);border-color:var(--terracotta);color:var(--paper)}
}


/* D-QA-01: compensate the main skip target once, including the sticky admin offset. */
html:lang(es) body.csp-system{--csp-skip-clearance:89px;--csp-root-anchor-padding:76px}
html:lang(es) body.csp-system.admin-bar{--csp-skip-clearance:121px}
html:lang(es) body.csp-system:is(.csp-hub,.csp-blog,.csp-article){--csp-root-anchor-padding:1.2rem}
html:lang(es) body.csp-system main#contenido{scroll-margin-top:calc(var(--csp-skip-clearance) - var(--csp-root-anchor-padding))}
@media(max-width:1020px){
  html:lang(es) body.csp-system{--csp-skip-clearance:83px;--csp-root-anchor-padding:70px}
  html:lang(es) body.csp-system.admin-bar{--csp-skip-clearance:115px}
}
@media(min-width:601px) and (max-width:782px){html:lang(es) body.csp-system.admin-bar{--csp-skip-clearance:129px}}
@media(max-width:600px){html:lang(es) body.csp-system.admin-bar{--csp-skip-clearance:83px}}

/* Keyboard focus uses one sticky-header clearance and no pending native smooth scroll. */
html:lang(es):has(body.csp-system :focus-visible){scroll-behavior:auto;scroll-padding-top:89px}
html:lang(es):has(body.csp-system.admin-bar :focus-visible){scroll-padding-top:121px}
html:lang(es):has(body.csp-system :focus-visible) body.csp-system main#contenido{scroll-margin-top:0}
@media(max-width:1020px){
  html:lang(es):has(body.csp-system :focus-visible){scroll-padding-top:83px}
  html:lang(es):has(body.csp-system.admin-bar :focus-visible){scroll-padding-top:115px}
}
@media(min-width:601px) and (max-width:782px){html:lang(es):has(body.csp-system.admin-bar :focus-visible){scroll-padding-top:129px}}
@media(max-width:600px){html:lang(es):has(body.csp-system.admin-bar :focus-visible){scroll-padding-top:83px}}

/* Menu movil de entradas EN: panel a ancho completo bajo la cabecera de 77 px (igual que ES). */
@media(max-width:1020px){body.csp-blog-pilot-en .et-l--header .pilot-mobile-menu nav{position:fixed;top:77px;left:0;right:0;width:100vw;max-width:100%;box-sizing:border-box;max-height:calc(100dvh - 77px)}body.csp-blog-pilot-en.admin-bar .et-l--header .pilot-mobile-menu nav{top:123px}}

/* Selector de idioma en cabecera de entradas: en linea con la navegacion, sin alterar los 77 px. */
@media(min-width:1021px){.et-l--header .et_pb_text_inner:has(>.csp-lh-switch){display:flex;align-items:center;gap:1.25rem}.et-l--header .csp-lh-switch{font:500 .72rem/1 Archivo,Arial,sans-serif;letter-spacing:.08em;text-transform:uppercase;white-space:nowrap}}
@media(max-width:1020px){.et-l--header .et_pb_text_inner>.csp-lh-switch{display:none}.et-l--header details .csp-lh-switch--mobile{display:block;padding:1rem 0;font:500 .8rem/1.4 Archivo,Arial,sans-serif;letter-spacing:.08em;text-transform:uppercase}.et-l--header .csp-lh-switch a{margin-right:.9rem}}

/* Índice ES: altura interior 76 px, más borde = 77 px. */
@media (max-width: 980px) { body.csp-blog .site-header__inner { min-height: 76px; } }

/* CSP-HOME-TECH-AMP */
.focus--technology .technology__visual{position:relative;display:block;min-height:100%;overflow:hidden}
.focus--technology .technology__visual .tech-orbit{right:auto;left:50%;top:36%;aspect-ratio:1/1;height:auto;transform:translate(-50%,-50%)}
.focus--technology .technology__visual .tech-orbit--one{width:min(88%,430px)}
.focus--technology .technology__visual .tech-orbit--two{width:min(56%,270px)}
.focus--technology .technology__visual::after{content:"";position:absolute;left:50%;transform:translateX(-50%);bottom:clamp(1.6rem,4vw,3.4rem);width:clamp(110px,40%,190px);aspect-ratio:280/232;background:var(--terracotta,#9D4F34);-webkit-mask:url("../svg/ampersand-historico-evolucionado.svg") center/contain no-repeat;mask:url("../svg/ampersand-historico-evolucionado.svg") center/contain no-repeat}
@media(max-width:1020px){.focus--technology .technology__visual{min-height:300px}}
