/*
 SÓCRATES NOVA · Ajustes responsive no destructivos · 2026-10-19
 Capa aditiva. No reemplaza estilos de marca ni contenidos de MySQL.
 Instalar DESPUÉS de las hojas del tema; ver LEEME.
*/

/* Cualquier bloque generado debe poder reducirse dentro de su columna. */
main#main :is(.spb-section,.spb-container,.spb-columns,.spb-column,.spb-widget,
 .spb-card,.spb-gallery,.spb-image-box,.spb-icon-box,.spb-testimonial,
 .spb-form,.spb-tabs,.spb-accordion) { min-width:0; max-width:100%; }
main#main .spb-columns > *,
main#main .spb-gallery > *,
main#main .spb-form > * {min-width:0;}
main#main :is(.spb-widget-image,.spb-image-box img,.spb-gallery img,
 .spb-widget-video) {max-width:100%;height:auto;}
main#main :is(.spb-widget-heading,.spb-widget-text,.spb-card,.spb-testimonial,
 .blog-card,.blog-article) {overflow-wrap:break-word;}
main#main :is(.spb-widget-text,.spb-widget-heading) :is(a,code,pre) {overflow-wrap:anywhere;}

/* Garantías para medios responsive en módulos propios y embebidos. */
main#main :is(.blog-cover,.blog-card img,.portfolio-card img,.stage-illustration,
 .essence-art-card img,.promise-art img) {max-width:100%;}
main#main :is(iframe,video,canvas,svg) {max-width:100%;}
main#main .spb-widget :is(iframe,video) {display:block;max-width:100%;}
main#main .spb-map {max-width:100%;}

/* Portátiles y tablet en vertical: evitar columnas desbordadas. */
@media (max-width:1024px) {
  .container,.header-inner {max-width:100%;}
  main#main :is(.hero-copy,.hero-stage,.essence-grid-rich > *,
   .human-tech-bottom > *,.promise-layout > *,.featured-project > *,
   .form-layout > *) {min-width:0;}
  main#main .spb-columns {gap:clamp(12px,2vw,24px);}
  main#main .spb-container {max-width:calc(100% - 24px);}
}

/* Móvil: navegación con altura de contenido, no una capa que salga de pantalla. */
@media (max-width:620px) {
  #primary-nav {
    height:auto;
    max-height:calc(100dvh - 128px);
    min-height:0;
    overflow-y:auto;
    overflow-x:hidden;
    overscroll-behavior:contain;
    -webkit-overflow-scrolling:touch;
    padding-bottom:20px;
  }
  #primary-nav > a {min-height:50px;}
  .header-inner {min-width:0;}
  .header-tools {min-width:0;}
  .announcement-main,.announcement-language {max-width:100%;}
  .footer-grid > *, .footer-links {min-width:0;}
  .footer-contact a {overflow-wrap:anywhere;}
  main#main :is(.hero-ctas,.hero-copy,.hero-title,.hero-lead,.essence-grid-rich,
   .human-tech-heading,.human-tech-bottom,.promise-content,.page-hero-inner,
   .blog-grid,.services-grid,.portfolio-grid,.form-grid) {min-width:0;max-width:100%;}
  main#main .spb-section {max-width:100%;}
  main#main .spb-columns {flex-direction:column;gap:16px;}
  main#main .spb-column {width:100%;max-width:100%;flex-basis:auto;}
  main#main .spb-container {width:calc(100% - 28px);max-width:100%;}
  main#main .spb-gallery {grid-template-columns:repeat(2,minmax(0,1fr));}
  main#main .spb-form {grid-template-columns:minmax(0,1fr);}
  main#main .spb-tab-nav {flex-wrap:wrap;}
  main#main :is(.spb-widget-button,.btn,.cta-orbit) {max-width:100%;}
  .chat-panel {max-width:calc(100vw - 14px);max-height:calc(100dvh - 145px);}
  .cookie-banner {max-height:calc(100dvh - 20px);overflow-y:auto;}
  .wa-float,.chat-trigger,.back-to-top {bottom:calc(var(--float-bottom, 15px) + env(safe-area-inset-bottom,0px));}
  .chat-trigger {--float-bottom:72px;}
  .back-to-top {--float-bottom:15px;}
  .chat-panel {bottom:calc(129px + env(safe-area-inset-bottom,0px));}
}

@media (max-width:365px) {
  #primary-nav {max-height:calc(100dvh - 126px);}
  .header-tools {gap:5px;}
  .lang-switch {gap:1px;}
  .hero-ctas .btn {white-space:normal;}
  main#main .spb-gallery {gap:8px;}
}

/* Si el visitante pide menos movimiento, respetarlo incluso en nuevas secciones. */
@media (prefers-reduced-motion:reduce) {
  html {scroll-behavior:auto;}
  .signal-ticker-track,.stage-illustration,.essence-art-card img,
  .promise-art img,.logo-cycle img {animation-duration:.001ms !important;}
}

/*
 * Actualización V2 — problemas verificados en auditoría de 2026-10-21.
 * Selectores explícitos, únicamente pantallas estrechas. Los !important se
 * limitan a anchuras/estructura necesarias para neutralizar estilos inline
 * normales que el Builder puede haber guardado en PT o ES.
 * No se alteran tipografías, colores, efectos ni contenido.
 */
@media (max-width: 620px) {
  /* PT: logo de 219–370px + herramientas empujaban el header hasta 480–516px. */
  html body .site-header .header-inner {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    flex-wrap: nowrap !important;
    box-sizing: border-box !important;
    width: calc(100% - 24px) !important;
    max-width: calc(100% - 24px) !important;
    min-width: 0 !important;
    gap: 7px !important;
    margin-inline: auto !important;
  }
  html body .site-header .header-inner > .brand {
    flex: 0 1 150px !important;
    width: 150px !important;
    max-width: 150px !important;
    min-width: 0 !important;
    margin: 0 !important;
  }
  html body .site-header .brand .logo-cycle.logo-cycle-header {
    display: block !important;
    position: relative !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    aspect-ratio: 30 / 7;
    min-width: 0 !important;
  }
  html body .site-header .brand .logo-cycle.logo-cycle-header img {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    object-fit: contain;
  }
  html body .site-header .header-tools {
    display: flex !important;
    flex: 0 0 auto !important;
    align-items: center !important;
    width: auto !important;
    max-width: calc(100% - 158px) !important;
    min-width: 0 !important;
    margin-left: auto !important;
    gap: 7px !important;
  }
  html body .site-header .lang-switch {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: flex-end !important;
    width: auto !important;
    max-width: 75px !important;
    min-width: 0 !important;
    gap: 3px !important;
  }
  html body .site-header .lang-switch a {
    display: inline-flex !important;
    justify-content: center !important;
    align-items: center !important;
    flex: 0 0 21px !important;
    width: 21px !important;
    min-width: 0 !important;
    max-width: 21px !important;
    padding: 0 !important;
  }
  html body .site-header .lang-switch a img {
    display: block;
    width: 21px !important;
    height: 21px !important;
    max-width: 100% !important;
  }
  html body .site-header .lang-switch a span {
    display: none !important;
  }
  html body .site-header .mobile-toggle {
    display: inline-flex !important;
    flex: 0 0 44px !important;
    width: 44px !important;
    min-width: 44px !important;
    max-width: 44px !important;
    padding: 8px !important;
  }

  /* ES: una columna 620px se salía de pantallas de 320–390px. */
  html body main#main .human-tech .human-tech-bottom {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }
  html body main#main .human-tech .human-tech-bottom > .human-tech-manifesto,
  html body main#main .human-tech .human-tech-bottom > .human-terminal {
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    grid-column: 1 / -1 !important;
    flex-basis: auto !important;
    margin-inline: 0 !important;
  }
  html body main#main .human-tech .human-tech-manifesto :is(h3,p) {
    max-width: 100% !important;
    min-width: 0 !important;
    width: auto !important;
    overflow-wrap: break-word;
  }
  html body main#main .human-tech .human-terminal :is(.terminal-top,.terminal-screen,.terminal-bottom) {
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
  }
  html body main#main .human-tech .human-terminal .terminal-top {
    flex-wrap: wrap !important;
    row-gap: 3px;
  }
  html body main#main .human-tech .human-terminal :is(code,pre) {
    max-width: 100%;
    overflow-wrap: anywhere;
    white-space: pre-wrap;
  }
}
@media (max-width: 365px) {
  html body .site-header .header-inner > .brand {
    flex-basis: 130px !important;
    width: 130px !important;
    max-width: 130px !important;
  }
  html body .site-header .header-tools {
    max-width: calc(100% - 136px) !important;
  }
}

/* =====================================================================
 * SÓCRATES NOVA · MOBILE EXPERIENCE V3 · 2026-10-21
 * Esta capa SOLO afecta a tablet vertical y móvil. Preserva escritorio,
 * contenidos, animaciones, paleta, plantillas PHP y datos de MySQL.
 * Corrige reglas rígidas de anchura, tipografía y disposición que puede
 * haber guardado el constructor visual desde su modo de escritorio.
 * ===================================================================== */

/* TABLET VERTICAL: aire, columnas con medidas flexibles y medios intactos. */
@media (min-width:621px) and (max-width:900px) {
  html body main#main :is(.hero-inner,.page-hero-inner,.essence-grid-rich,
     .promise-layout,.human-tech-heading,.human-tech-bottom,.story-layout,
     .form-layout) {grid-template-columns:minmax(0,1fr) !important;}
  html body main#main :is(.hero-copy,.page-hero-copy,.hero-stage,
    .human-tech-manifesto,.human-terminal,.essence-art,.promise-art) {
    min-width:0;max-width:100%;}
  html body main#main .spb-columns {flex-wrap:wrap;}
  html body main#main .spb-column {min-width:0;}
  html body main#main img:not(.icon) {max-width:100%;}
}

/* CELULAR: composición vertical deliberada, no miniaturizar la versión PC. */
@media (max-width:620px) {
  html {text-size-adjust:100%;-webkit-text-size-adjust:100%;}
  html body :is(.container,.header-inner) {box-sizing:border-box;min-width:0;}
  html body main#main {min-width:0;max-width:100%;}
  html body main#main > :is(section,article) {max-width:100%;}

  /* Evita que los estilos inline del Builder mantengan columnas de PC. */
  html body main#main :is(.hero-inner,.page-hero-inner,.essence-grid,
    .essence-grid-rich,.human-tech-heading,.human-tech-bottom,.promise-layout,
    .story-layout,.form-layout,.value-layout,.prelude-inner,
    .featured-project) {
    display:grid !important;
    grid-template-columns:minmax(0,1fr) !important;
    gap:clamp(18px,5vw,32px) !important;
    min-width:0 !important;max-width:100% !important;
  }
  html body main#main :is(.hero-inner,.page-hero-inner,.essence-grid-rich,
    .promise-layout,.human-tech-bottom) > * {
    min-width:0 !important;max-width:100% !important;
    grid-column:1 / -1 !important;
  }
  html body main#main .human-equation {
    display:grid !important;
    grid-template-columns:minmax(0,1fr) !important;
    gap:12px !important;
    align-items:stretch !important;
  }
  html body main#main .human-equation-card {
    box-sizing:border-box;min-width:0 !important;max-width:100% !important;
    padding:clamp(18px,5vw,25px) !important;
  }
  html body main#main .equation-symbol {
    position:static !important;transform:none !important;
    justify-self:center !important;margin:0 !important;
    font-size:clamp(24px,7vw,34px) !important;line-height:1 !important;
  }
  html body main#main .human-tech-manifesto,
  html body main#main .human-terminal,
  html body main#main .human-tech-intro {
    width:100% !important;max-width:100% !important;min-width:0 !important;
    box-sizing:border-box !important;
  }
  html body main#main .human-terminal :is(pre,code) {white-space:pre-wrap;overflow-wrap:anywhere;}

  /* Escala editorial para móvil aun cuando se haya redimensionado en PC. */
  html body main#main :is(.hero-title,.page-hero h1) {
    font-size:clamp(35px,10.6vw,54px) !important;
    line-height:1.08 !important;
    overflow-wrap:break-word;
    max-width:100% !important;
  }
  html body main#main :is(.human-tech-title,.essence-title,.mid-heading,
    .prelude-inner h2) {
    font-size:clamp(29px,8.7vw,43px) !important;
    line-height:1.14 !important;
    overflow-wrap:break-word;max-width:100% !important;
  }
  html body main#main :is(.human-tech-manifesto h3,.featured-copy h2,
    .portfolio-heading h2,.section-bar h2) {
    font-size:clamp(25px,7.3vw,37px) !important;
    line-height:1.2 !important;
    overflow-wrap:break-word;max-width:100% !important;
  }
  html body main#main :is(.hero-lead,.essence-lead,.human-tech-intro,
    .human-tech-manifesto>p,.promise-content>p,.page-hero p) {
    font-size:clamp(15px,4.2vw,17px) !important;
    line-height:1.55 !important;
    overflow-wrap:break-word;
  }
  html body main#main :is(.hero-copy,.hero-lead,.human-tech-manifesto,
    .human-tech-manifesto h3,.human-tech-manifesto p,.promise-content,
    .featured-copy) {height:auto !important;min-height:0 !important;}

  /* Secciones y materiales: encuadre, orden natural y gestos táctiles. */
  html body main#main :is(.hero-stage,.hero-stage-illustrated) {
    width:100% !important;max-width:100% !important;
    height:clamp(260px,83vw,355px) !important;
    min-height:0 !important;
    margin:14px auto 0 !important;
  }
  html body main#main :is(.stage-illustration,.essence-art img,.promise-art img,
     .portfolio-card img,.blog-card img,.spb-widget-image) {
    display:block;max-width:100% !important;
    object-fit:contain;
  }
  html body main#main :is(.hero-ctas,.footer-social) {
    display:flex;flex-wrap:wrap;gap:10px;max-width:100%;
  }
  html body main#main .hero-ctas>.btn {flex:1 1 100%;white-space:normal;}
  html body main#main :is(.services-grid,.method-grid,.portfolio-grid,.blog-grid,
     .support-cards,.form-grid,.spb-gallery) {
    grid-template-columns:minmax(0,1fr) !important;
    min-width:0;max-width:100%;
  }
  html body main#main :is(.service-card,.method-card,.portfolio-card,
    .support-card,.blog-card) {box-sizing:border-box;min-width:0;max-width:100%;}
  html body main#main :is(.service-card,.method-card,.support-card) {
    height:auto !important;min-height:0 !important;
  }

  /* Builder: neutralizar geometrías rígidas desktop SOLO en móvil.
     Mantener colores, sombras, fuentes, bordes y contenidos elegidos. */
  html body main#main .spb-section {
    box-sizing:border-box;width:100% !important;max-width:100% !important;
    min-width:0 !important;padding:clamp(32px,8vw,52px) 0 !important;
    left:auto !important;right:auto !important;
  }
  html body main#main :is(.spb-container,.spb-columns,.spb-column) {
    box-sizing:border-box !important;
    min-width:0 !important;max-width:100% !important;
  }
  html body main#main .spb-container {
    width:calc(100% - 30px) !important;
    margin-inline:auto !important;
    height:auto !important;
  }
  html body main#main .spb-columns {
    display:flex !important;flex-direction:column !important;
    align-items:stretch !important;gap:20px !important;
    height:auto !important;
  }
  html body main#main .spb-column {
    display:block;flex:0 1 auto !important;
    width:100% !important;height:auto !important;
    margin-inline:0 !important;
  }
  html body main#main .spb-widget {
    min-width:0 !important;max-width:100% !important;
    box-sizing:border-box !important;
  }
  html body main#main .spb-widget-heading {
    font-size:clamp(26px,7.5vw,40px) !important;
    line-height:1.16 !important;
    overflow-wrap:break-word;
  }
  html body main#main .spb-widget-text,
  html body main#main .spb-widget-text :is(p,li,span) {
    line-height:1.6 !important;overflow-wrap:break-word;
  }
  html body main#main :is(.spb-widget-button,.spb-icon-box,.spb-image-box,
      .spb-card,.spb-testimonial,.spb-counter,.spb-map,.spb-accordion,.spb-tabs) {
    max-width:100% !important;box-sizing:border-box !important;
  }
  html body main#main .spb-widget-image,
  html body main#main .spb-gallery img {
    width:100% !important;height:auto !important;max-height:none !important;
    object-fit:contain !important;
  }
  html body main#main :is(.spb-image-box img,.spb-card img) {max-width:100%;height:auto;}
  html body main#main :is(.spb-widget iframe,.spb-map) {width:100% !important;max-width:100% !important;}
  html body main#main .spb-form {grid-template-columns:minmax(0,1fr) !important;}
  html body main#main .spb-form > * {min-width:0;max-width:100%;grid-column:auto;}

  /* Footer: bloques respirables y accesibles al tacto. */
  html body .footer-grid {max-width:100%;min-width:0;gap:26px 16px !important;}
  html body .footer-links>a,html body .footer-links>button,
  html body .footer-contact>a {min-height:34px;align-items:center;}
  html body .footer-base {overflow-wrap:break-word;}
}

/* 320–420 px: una columna completa también en el footer. */
@media (max-width:420px) {
  html body .footer-grid {
    display:grid !important;grid-template-columns:minmax(0,1fr) !important;
    gap:25px !important;
  }
  html body .footer-grid > * {grid-column:1 / -1 !important;min-width:0 !important;}
  html body .footer-contact {display:flex !important;flex-direction:column !important;align-items:flex-start !important;}
  html body .footer-identity .logo-cycle-footer {max-width:min(230px,100%) !important;}
  html body main#main :is(.hero-title,.page-hero h1) {font-size:clamp(32px,10vw,41px) !important;}
  html body main#main :is(.stage-illustration-wrap,.promise-art,.essence-art-card) {max-width:100%;}
  html body main#main .spb-section {padding-block:36px !important;}
}

/* Respetar movimiento reducido también en imágenes y widgets del Builder. */
@media (prefers-reduced-motion:reduce) {
  html body main#main :is(.spb-widget,.stage-illustration,.human-tech-title) {
    scroll-behavior:auto;transition:none !important;
  }
}

/* Las posiciones absolutas arrastradas en escritorio no deben superponer
   widgets nuevos en un teléfono. No altera los que tienen posición propia
   configurada específicamente para celular por el usuario. */
@media (max-width:767px) {
  html body main#main .spb-container > .spb-widget:not([data-spb-mobile])[style*="position:absolute"],
  html body main#main .spb-container > .spb-widget:not([data-spb-mobile])[style*="position: absolute"],
  html body main#main .spb-column > .spb-widget:not([data-spb-mobile])[style*="position:absolute"],
  html body main#main .spb-column > .spb-widget:not([data-spb-mobile])[style*="position: absolute"] {
    position:relative !important;inset:auto !important;
    transform:none !important;float:none !important;
    width:auto !important;max-width:100% !important;
    margin:12px 0 !important;
  }
}


/* ================================================================
   SÓCRATES NOVA V20.3.21 · MOBILE HOTFIX — 29 OCT 2026
   Guardas adicionales después de la auditoría de navegación y visual.
   La vista desktop (más de 1100px) no se modifica. Ningún texto,
   documento, idioma, CTA, cookie, módulo o formulario se reescribe.
   ================================================================ */

/* Impedir que contenidos con columnas rígidas fuercen scroll horizontal. */
@media (max-width:1100px) {
  html { overflow-x:clip; }
  body { min-width:0; overflow-x:clip; }
  html body :is(.container,.header-inner,.footer-grid,.footer-base,
    .page-hero-inner,.hero-inner,.essence-grid-rich,.human-tech,
    .human-tech-heading,.human-tech-bottom,.promise-layout,.story-layout,
    .services-grid,.portfolio-grid,.blog-grid,.form-layout,.featured-project,
    .spb-section,.spb-columns,.spb-container,.spb-column,.spb-widget) {
      box-sizing:border-box;min-width:0;max-width:100%;
    }
  html body :is(.hero-copy,.page-hero-copy,.essence-copy,.promise-content,
    .human-tech-intro,.human-tech-manifesto,.human-terminal,.featured-copy,
    .footer-identity,.footer-links,.footer-contact) { min-width:0; }
  html body :is(img,picture,video) { max-width:100%; }
  html body main#main :is(h1,h2,h3,h4,h5,h6,p,li,a,button) {
      word-break:normal; overflow-wrap:break-word;
    }
  html body main#main :is(pre,code) {max-width:100%;overflow-wrap:anywhere;}
  html body main#main :is(iframe,video,canvas) {max-width:100%;}
  html body .site-header .primary-nav.open {
    overscroll-behavior:contain;
    -webkit-overflow-scrolling:touch;
  }
}

@media (min-width:621px) and (max-width:1100px) {
  /* El botón de menú existe en la plantilla: hacerlo visible sin ocultar idiomas. */
  html body .site-header .header-inner {
    width:calc(100% - 40px);
    max-width:100%;
    flex-wrap:nowrap;
  }
  html body .site-header .header-inner > .brand {min-width:0;flex-shrink:1;}
  html body .site-header .header-tools {margin-left:auto;min-width:0;}
  html body .site-header .primary-nav.open {overflow-y:auto;overflow-x:hidden;}
  html body main#main :is(.essence-grid-rich,.human-tech-bottom,
    .promise-layout,.story-layout,.form-layout,.page-hero-inner) {
    grid-template-columns:minmax(0,1fr) !important;
  }
  html body main#main :is(.essence-grid-rich,.human-tech-bottom,
    .promise-layout,.story-layout,.form-layout,.page-hero-inner) > * {
    min-width:0;max-width:100%;
  }
}

@media (max-width:767px) {
  /* No alterar elementos animados nativos: solo widgets movidos en PC. */
  html body main#main .spb-section :is(.spb-columns,.spb-column) {
    display:flex !important;
    flex-direction:column !important;
    align-items:stretch !important;
    height:auto !important;
  }
  html body main#main .spb-section :is(.spb-column,.spb-widget) {
    flex:0 1 auto !important;
    min-width:0 !important;
    max-width:100% !important;
  }
  html body main#main .spb-section .spb-widget:is([style*="width:"],[style*="min-width:"]) {
    max-width:100% !important;
    min-width:0 !important;
  }
  html body main#main .spb-section :is(.spb-gallery,.spb-form-fields) {
    grid-template-columns:minmax(0,1fr) !important;
  }
  html body main#main .spb-section :is(.spb-widget-image,.spb-widget-video,
    .spb-gallery img,.spb-image-box img) {
    width:auto;max-width:100% !important;height:auto !important;
  }
  html body main#main .spb-section .spb-tab-nav {
    flex-wrap:wrap !important;
    min-width:0 !important;
  }
  html body main#main .spb-section .spb-tab-nav > button {min-height:44px;}
}

@media (max-width:620px) {
  html { -webkit-text-size-adjust:100%;text-size-adjust:100%; }

  /* Header: logo + banderas redondas + menú accesible incluso en 320px. */
  html body .site-header,
  html body .site-header.scrolled {height:66px !important;min-height:66px !important;}
  html body .site-header .header-inner > .brand {flex-shrink:1 !important;}
  html body .site-header .header-tools {flex-shrink:0 !important;}
  html body .site-header .primary-nav {
    box-sizing:border-box;
    width:100%;
    max-width:100%;
    top:100%;
    overflow-x:hidden;
    overflow-y:auto;
    max-height:calc(100dvh - 76px) !important;
    padding:14px clamp(16px,5vw,30px) 24px !important;
    -webkit-overflow-scrolling:touch;
    overscroll-behavior:contain;
  }
  html body .site-header .primary-nav:not(.open) {display:none !important;}
  html body .site-header .primary-nav.open {display:flex !important;}
  html body .site-header .primary-nav > a {
    width:100%;min-height:49px !important;
    white-space:normal !important;
    overflow-wrap:break-word;
  }
  html body .site-header .mobile-toggle {touch-action:manipulation;}

  /* Portada: 1 columna, foto completa, botones táctiles, sin recortes. */
  html body main#main .home-hero .hero-inner {
    display:grid !important;
    grid-template-columns:minmax(0,1fr) !important;
    width:calc(100% - 36px);
    gap:12px !important;
    padding-block:clamp(32px,8vw,48px) 16px !important;
    min-height:0 !important;
  }
  html body main#main .home-hero :is(.hero-copy,.hero-stage) {
    grid-column:1 / -1 !important;
    min-width:0 !important;
    max-width:100% !important;
  }
  html body main#main .home-hero .hero-stage.hero-stage-people {
    display:flex !important;
    align-items:center !important;
    justify-content:center !important;
    height:auto !important;
    min-height:0 !important;
    max-height:none !important;
    margin:10px auto 0 !important;
  }
  html body main#main .home-hero .hero-people-image {
    display:block;
    width:100% !important;
    max-width:100% !important;
    height:auto !important;
    object-fit:contain !important;
  }
  html body main#main .hero-ctas {width:100%;flex-direction:column;gap:10px !important;}
  html body main#main .hero-ctas .btn {width:100% !important;min-width:0 !important;}
  html body main#main :is(.hero-title,.page-hero h1) {
    max-width:100% !important;
    font-size:clamp(34px,10vw,49px) !important;
    line-height:1.06 !important;
    overflow-wrap:break-word;
    hyphens:none;
    text-wrap:pretty;
  }
  html body main#main .home-hero :is(.hero-kicker,.hero-lead) {max-width:100% !important;}
  html body main#main .hero-bottom {gap:9px;flex-wrap:wrap;}

  /* DNA HUMANO + IA, terminal y secciones inferiores sin superposiciones. */
  html body main#main :is(.human-tech-heading,.human-tech-bottom,
    .human-equation,.essence-grid-rich,.promise-layout,.page-hero-inner,
    .story-layout,.form-layout,.value-layout) {
      display:grid !important;
      grid-template-columns:minmax(0,1fr) !important;
      min-width:0 !important;
      max-width:100% !important;
  }
  html body main#main .human-equation > .equation-symbol {
    display:grid !important;
    place-items:center;
    position:static !important;
    transform:none !important;
  }
  html body main#main .human-equation-card.is-result {grid-column:1 !important;}
  html body main#main .human-equation-card.is-result ul {
    grid-template-columns:minmax(0,1fr) !important;
  }
  html body main#main .human-tech-bottom > *,
  html body main#main .promise-layout > *,
  html body main#main .essence-grid-rich > * {
    min-width:0 !important;
    width:100% !important;
    max-width:100% !important;
  }
  html body main#main .human-terminal :is(pre,code,.terminal-screen) {
    min-width:0;max-width:100%;overflow-wrap:anywhere;
  }
  html body main#main .terminal-screen {overflow-x:auto;}
  html body main#main :is(.human-tech-title,.essence-title,.mid-heading) {
    font-size:clamp(30px,8.7vw,43px) !important;
    line-height:1.13 !important;
    max-width:100% !important;
  }

  /* Tarjetas, formulario y fotografía: columna única, sin alturas fijas. */
  html body main#main :is(.services-grid,.method-grid,.portfolio-grid,
    .blog-grid,.support-cards,.form-grid,.spb-gallery,.spb-form,
    .spb-form-fields) {grid-template-columns:minmax(0,1fr) !important;}
  html body main#main :is(.service-card,.method-card,.portfolio-card,
    .blog-card,.support-card,.featured-copy,.featured-visual,.form-surface) {
    min-width:0 !important;max-width:100% !important;height:auto;
  }
  html body main#main :is(.spb-widget,.spb-column,.spb-section) {
    min-width:0 !important;max-width:100% !important;
  }
  html body main#main :is(.spb-widget-heading,.human-tech-title,.mid-heading) {
    word-break:normal;overflow-wrap:break-word;
  }
  html body main#main :is(.btn,.spb-widget-button) {
    max-width:100% !important;touch-action:manipulation;
    white-space:normal !important;
  }
  html body main#main :is(input,select,textarea) {max-width:100%;min-width:0;}

  /* Pie y asistentes: contenedor vertical, espacio para acciones flotantes. */
  html body .footer-grid {min-width:0 !important;max-width:100% !important;}
  html body .footer-grid > * {min-width:0 !important;max-width:100% !important;}
  html body .footer-contact :is(a,span) {max-width:100%;overflow-wrap:anywhere;}
  html body .footer-base {flex-wrap:wrap;max-width:100%;}
  html body :is(.chat-panel,.cookie-banner,.locale-offer) {box-sizing:border-box;max-width:calc(100vw - 16px);}
  html body .chat-panel {max-height:calc(100dvh - 145px);overflow-y:auto;}
  html body .cookie-banner {max-height:calc(100dvh - 24px);overflow-y:auto;}
}

@media (max-width:420px) {
  html body .footer-grid {
    grid-template-columns:minmax(0,1fr) !important;
    gap:24px !important;
  }
  html body .footer-grid > * {grid-column:1 / -1 !important;}
  html body .footer-contact {grid-column:1 / -1 !important;}
  html body .footer-giant {font-size:clamp(55px,16vw,72px);}
}

/* Accesibilidad: teclado y personas con sensibilidad al movimiento. */
@media (hover:none) and (pointer:coarse) {
  html body :is(.btn,.mobile-toggle,.primary-nav a,.footer-links a,.lang-switch a) {
    -webkit-tap-highlight-color:rgba(255,255,255,.16);
  }
}
@media (prefers-reduced-motion:reduce) {
  html {scroll-behavior:auto;}
}


/* ======================================================================
   V20.3.22 · FIX VISUAL VERIFICADO CON CAPTURAS DEL 29/10/2026
   El Builder puede agregar reglas después del CSS de cabecera: el JS de
   esta versión reubica esta hoja después de #nova-sp-published-css.
   Solo cambia composición en pantallas reducidas, jamás datos publicados.
   ====================================================================== */
@media (max-width:767px) {
  html, body { max-width:100%; overflow-x:clip; }
  html body main#main, html body main#main > section,
  html body .footer-prelude, html body .footer-prelude .prelude-inner {
    box-sizing:border-box; min-width:0; max-width:100%;
  }
  /* HÉROE: evitar que spans del título hereden fuentes inline de PC
     incluso si el h1 ya está reducido. */
  html body main#main .home-hero .hero-inner {
    display:grid !important;
    grid-template-columns:minmax(0,1fr) !important;
    width:calc(100% - 32px) !important;
    max-width:620px !important;
    min-width:0 !important;
    margin-inline:auto !important;
    gap:18px !important;
    transform:none !important;
    padding:clamp(30px,8vw,48px) 0 18px !important;
  }
  html body main#main .home-hero .hero-copy {
    grid-column:1 !important; grid-row:auto !important;
    box-sizing:border-box !important; min-width:0 !important;
    width:100% !important; max-width:100% !important;
    position:relative !important; inset:auto !important;
    transform:none !important; margin:0 !important; padding:0 !important;
  }
  html body main#main .home-hero .hero-title {
    box-sizing:border-box !important;
    width:100% !important; min-width:0 !important; max-width:100% !important;
    margin:18px 0 14px !important;
    padding:0 !important;
    font-size:clamp(36px,9.5vw,52px) !important;
    line-height:1.01 !important; letter-spacing:-.02em !important;
    white-space:normal !important; word-break:normal !important;
    overflow-wrap:break-word !important; text-wrap:balance;
    text-align:left !important; transform:none !important;
    position:static !important; inset:auto !important;
  }
  html body main#main .home-hero .hero-title > span,
  html body main#main .home-hero .hero-title > span :is(span,b,strong,i,em) {
    box-sizing:border-box !important;
    display:block !important; float:none !important;
    width:auto !important; min-width:0 !important; max-width:100% !important;
    font-size:inherit !important; line-height:inherit !important;
    letter-spacing:inherit !important;
    white-space:normal !important; word-break:normal !important;
    overflow-wrap:break-word !important;
    margin-inline:0 !important;
    transform:none !important; position:static !important; inset:auto !important;
  }
  html body main#main .home-hero .hero-kicker {
    box-sizing:border-box !important; min-width:0 !important;
    width:100% !important; max-width:100% !important;
    font-size:clamp(16px,4.3vw,21px) !important;
    line-height:1.35 !important; white-space:normal !important;
    overflow-wrap:break-word !important; transform:none !important;
    position:static !important; inset:auto !important;
  }
  html body main#main .home-hero .hero-lead {
    box-sizing:border-box !important; width:100% !important;
    min-width:0 !important; max-width:100% !important;
    font-size:clamp(15px,4.05vw,17px) !important;
    line-height:1.55 !important;
    white-space:normal !important; overflow-wrap:break-word !important;
    transform:none !important;
  }
  html body main#main .home-hero .hero-ctas {
    position:static !important; transform:none !important;
    margin:20px 0 0 !important; width:100% !important;
    display:flex !important; flex-direction:column !important;
  }
  html body main#main .home-hero .hero-stage {
    grid-column:1 !important; grid-row:auto !important;
    width:100% !important; max-width:100% !important;
    position:relative !important; inset:auto !important;
    transform:none !important; margin:0 !important;
  }
  /* CTA VERDE de la captura: está FUERA de main#main. Las reglas
     anteriores para .prelude-inner no le llegaban. */
  html body .footer-prelude {
    width:100% !important; max-width:100% !important;
    height:auto !important; min-height:0 !important;
    padding:clamp(42px,12vw,66px) 0 !important;
    overflow:hidden;
  }
  html body .footer-prelude .prelude-inner {
    display:grid !important;
    grid-template-columns:minmax(0,1fr) !important;
    grid-auto-flow:row !important;
    align-items:start !important;
    justify-items:stretch !important;
    width:calc(100% - 36px) !important;
    max-width:620px !important;
    min-width:0 !important;
    margin:0 auto !important;
    padding:0 !important;
    gap:22px !important;
    height:auto !important; min-height:0 !important;
    position:relative !important; inset:auto !important;
    transform:none !important;
  }
  html body .footer-prelude .prelude-inner > *,
  html body .footer-prelude .footer-cta-copy {
    box-sizing:border-box !important;
    display:block !important;
    grid-column:1 !important; grid-row:auto !important;
    width:100% !important; min-width:0 !important; max-width:100% !important;
    height:auto !important; min-height:0 !important;
    margin:0 !important; padding:0 !important;
    position:relative !important; inset:auto !important;
    transform:none !important;
    float:none !important;
  }
  html body .footer-prelude .footer-cta-copy .eyebrow {
    display:flex !important; align-items:center !important;
    flex-wrap:wrap !important; gap:8px !important;
    width:100% !important; max-width:100% !important;
    position:static !important; transform:none !important;
    font-size:clamp(12px,3.5vw,15px) !important;
    white-space:normal !important;
  }
  html body .footer-prelude .footer-cta-copy h2 {
    width:100% !important; min-width:0 !important; max-width:100% !important;
    height:auto !important; padding:0 !important;
    margin:16px 0 20px !important;
    font-size:clamp(31px,8.2vw,45px) !important;
    line-height:1.08 !important;
    white-space:normal !important; word-break:normal !important;
    overflow-wrap:break-word !important;
    text-align:left !important; transform:none !important;
    position:static !important; inset:auto !important;
  }
  html body .footer-prelude .footer-cta-copy h2 span,
  html body .footer-prelude .footer-cta-copy h2 span :is(span,b,strong,em,i) {
    display:block !important;
    width:auto !important; min-width:0 !important; max-width:100% !important;
    font-size:inherit !important; line-height:inherit !important;
    letter-spacing:inherit !important;
    white-space:normal !important; word-break:normal !important;
    overflow-wrap:break-word !important;
    position:static !important; inset:auto !important;
    transform:none !important;
  }
  html body .footer-prelude .footer-cta-copy p,
  html body .footer-prelude .footer-cta-copy p :is(span,b,strong,em,i) {
    width:100% !important; max-width:100% !important;
    height:auto !important;
    font-size:clamp(15px,4vw,17px) !important;
    line-height:1.55 !important;
    white-space:normal !important; overflow-wrap:break-word !important;
    transform:none !important; position:static !important; inset:auto !important;
  }
  html body .footer-prelude .footer-cta-copy .footer-cta-button {
    box-sizing:border-box !important;
    position:relative !important; inset:auto !important;
    display:inline-flex !important; align-items:center !important;
    flex-wrap:wrap !important; justify-content:center !important;
    width:auto !important; max-width:100% !important; min-width:0 !important;
    height:auto !important; min-height:52px !important;
    margin:0 !important; padding:14px 18px !important;
    font-size:clamp(12px,3.3vw,14px) !important;
    line-height:1.35 !important; white-space:normal !important;
    text-align:center !important; transform:none !important;
  }
  html body .footer-prelude .footer-cta-art {
    display:flex !important; justify-content:center !important;
    align-items:center !important; grid-column:1 !important;
    width:100% !important; max-width:100% !important;
    margin:0 auto !important; padding:0 !important;
    min-width:0 !important; height:auto !important;
    transform:none !important;
  }
  html body .footer-prelude .footer-cta-art img {
    display:block !important; object-fit:contain !important;
    width:100% !important; max-width:480px !important;
    height:auto !important; max-height:320px !important;
    transform:none !important;
  }
  /* Evita recorte del texto auxiliar y secciones de contenidos agregadas. */
  html body main#main :is(.eyebrow,.section-label,.spb-widget-heading,.spb-widget-text) {
    white-space:normal; min-width:0; max-width:100%;
  }
  html body main#main .spb-section [style*="min-width"] {
    max-width:100% !important;
  }
}
@media (max-width:380px) {
 html body main#main .home-hero .hero-title {font-size:clamp(32px,9.4vw,36px) !important;}
 html body .footer-prelude .footer-cta-copy h2 {font-size:clamp(29px,8vw,35px) !important;}
}

/* SÓCRATES NOVA 20.3.23: ajuste del espacio del hero y el CTA final en
   móviles reales. Estilos encapsulados; no se altera contenido ni escritorio. */
@media screen and (max-width: 767px) {
  html body main#main section.home-hero {
    box-sizing:border-box !important;
    height:auto !important; min-height:0 !important; max-height:none !important;
    padding:0 !important; margin:0 !important;
    overflow-x:clip !important;
  }
  html body main#main .home-hero .hero-inner {
    box-sizing:border-box !important;
    display:grid !important; grid-template-columns:minmax(0,1fr) !important;
    align-content:start !important; align-items:start !important;
    width:calc(100% - 32px) !important; max-width:620px !important;
    height:auto !important; min-height:0 !important; max-height:none !important;
    margin:0 auto !important; padding:clamp(22px,6vw,36px) 0 12px !important;
    gap:12px !important; transform:none !important; translate:none !important;
  }
  html body main#main .home-hero .hero-copy {
    box-sizing:border-box !important;
    grid-column:1 !important; grid-row:auto !important;
    width:100% !important; max-width:100% !important; min-width:0 !important;
    height:auto !important; min-height:0 !important; max-height:none !important;
    margin:0 !important; padding:0 !important;
    inset:auto !important; position:relative !important;
    transform:none !important; translate:none !important;
    align-self:start !important; justify-self:stretch !important;
  }
  html body main#main .home-hero .hero-stage.hero-stage-people {
    box-sizing:border-box !important;
    grid-column:1 !important; grid-row:auto !important;
    width:100% !important; min-width:0 !important; max-width:100% !important;
    height:auto !important; min-height:0 !important; max-height:none !important;
    margin:0 auto !important; padding:0 !important;
    position:relative !important; inset:auto !important;
    transform:none !important; translate:none !important;
    align-self:start !important; justify-self:center !important;
  }
  html body main#main .home-hero .hero-stage-people .hero-people-image {
    box-sizing:border-box !important; display:block !important;
    width:100% !important; max-width:100% !important;
    height:auto !important; max-height:min(78vw,340px) !important;
    margin:0 auto !important; padding:0 !important;
    object-fit:contain !important; object-position:center !important;
    position:static !important; inset:auto !important;
    transform:none !important; translate:none !important;
  }
  html body main#main .home-hero .hero-bottom {
    position:relative !important; left:auto !important; right:auto !important;
    top:auto !important; bottom:auto !important;
    transform:none !important; translate:none !important;
    box-sizing:border-box !important; width:calc(100% - 32px) !important;
    max-width:620px !important; height:auto !important; min-height:0 !important;
    padding:4px 0 16px !important; margin:0 auto !important;
  }
  html body .footer-prelude {
    box-sizing:border-box !important;
    display:block !important; width:100% !important; max-width:100% !important;
    height:auto !important; min-height:0 !important; max-height:none !important;
    padding:clamp(35px,9vw,56px) 0 !important;
    margin:0 !important;
    overflow-x:clip !important;
  }
  html body .footer-prelude .prelude-inner {
    box-sizing:border-box !important; display:flex !important;
    flex-direction:column !important; flex-wrap:nowrap !important;
    align-items:stretch !important; justify-content:flex-start !important;
    width:calc(100% - 36px) !important; max-width:620px !important;
    min-width:0 !important; height:auto !important; min-height:0 !important;
    margin:0 auto !important; padding:0 !important; gap:20px !important;
    position:relative !important; inset:auto !important;
    transform:none !important; translate:none !important;
    float:none !important;
  }
  html body .footer-prelude .prelude-inner > .footer-cta-copy,
  html body .footer-prelude .prelude-inner > .footer-cta-art {
    box-sizing:border-box !important;
    flex:0 1 auto !important; float:none !important;
    grid-column:auto !important; grid-row:auto !important;
    width:100% !important; max-width:100% !important; min-width:0 !important;
    height:auto !important; min-height:0 !important; max-height:none !important;
    margin:0 !important; padding:0 !important;
    position:relative !important; inset:auto !important;
    transform:none !important; translate:none !important;
    align-self:stretch !important; justify-self:stretch !important;
  }
  html body .footer-prelude .prelude-inner > .footer-cta-copy {order:0 !important;}
  html body .footer-prelude .prelude-inner > .footer-cta-art {order:1 !important;}
  html body .footer-prelude .footer-cta-copy :is(.eyebrow,h2,p,a.footer-cta-button),
  html body .footer-prelude .footer-cta-copy h2 > span {
    box-sizing:border-box !important;
    max-width:100% !important; min-width:0 !important;
    margin-left:0 !important; margin-right:0 !important;
    left:auto !important; right:auto !important;
    translate:none !important; transform:none !important;
  }
  html body .footer-prelude .footer-cta-copy h2 {
    font-size:clamp(30px,8vw,43px) !important;
    line-height:1.08 !important;
    margin-top:12px !important; margin-bottom:16px !important;
    height:auto !important; width:100% !important;
    white-space:normal !important; text-align:left !important;
    overflow-wrap:break-word !important;
  }
  html body .footer-prelude .footer-cta-copy h2 > span,
  html body .footer-prelude .footer-cta-copy h2 > span * {
    font-size:inherit !important; line-height:inherit !important;
    white-space:normal !important; overflow-wrap:break-word !important;
  }
  html body .footer-prelude .footer-cta-copy p {
    font-size:clamp(15px,3.9vw,17px) !important; line-height:1.5 !important;
    height:auto !important; width:100% !important;
    margin-top:0 !important; margin-bottom:20px !important;
    white-space:normal !important; overflow-wrap:break-word !important;
  }
  html body .footer-prelude .footer-cta-button {
    box-sizing:border-box !important;
    display:inline-flex !important; width:auto !important; max-width:100% !important;
    height:auto !important; min-height:52px !important;
    align-items:center !important; justify-content:center !important;
    gap:9px !important; padding:14px 17px !important;
    font-size:clamp(11px,3vw,14px) !important;
    white-space:normal !important; text-align:center !important;
  }
  html body .footer-prelude .footer-cta-art img {
    display:block !important;
    width:100% !important; height:auto !important; max-height:300px !important;
    max-width:100% !important; margin:0 auto !important;
    object-fit:contain !important; object-position:center !important;
  }
}
