/* ============================================================
   Los Altillos — Legibilidad y objetivos táctiles en MÓVIL
   Archivo: assets/ux-mobile.css (29/9/2026)
   Se encola DESPUÉS de todas las hojas (main, header, footer,
   content, la de cada plantilla y el <style id="la-movil"> de
   functions.php): varias reglas ganan solo por orden.
   Todo va dentro de @media (max-width: 767px) salvo la raíz,
   que usa 768px para calzar exacto con el bloque 26.
   No cambia escritorio, colores, marca ni estructura.
   Base: auditoría Pixel 5 (393 px) de las 64 URLs (ux/baseline)
   → resultado en ux/after-typo y ux/TYPO-REPORT.md.
   Objetivos: texto de lectura >= 15-16 px, secundario >= 14 px,
   etiquetas en MAYÚSCULAS >= 12 px, nada legible < 12 px;
   enlaces/botones/chips/toggles >= 44 px de alto de toque.
   ============================================================ */

/* ------------------------------------------------------------
   0 · RAÍZ
   El bloque 26 de functions.php pone :root{font-size:15px} en
   móvil y casi todo el sitio escribe en rem: el texto quedaba un
   6 % por debajo de lo diseñado (0.875rem = 13.1 px). Se lleva
   la raíz a 16 px. Las páginas de Colombia (escala propia sobre
   la raíz de 12 px de main.css) quedan afuera, con la misma
   lista de IDs que $escala_propia en functions.php.
   html:root (0,1,1) le gana a :root (0,1,0) sin importar orden.
   Sin soporte de :has() la regla se descarta y queda el 15 px.
   ------------------------------------------------------------ */
@media (max-width: 768px) {
  html:root:not(:has(> body:is(.page-id-276, .page-id-283, .page-id-285, .page-id-370, .page-id-371, .page-id-372, .page-id-378, .page-id-379, .page-id-380, .page-id-384, .page-id-385, .page-id-386, .page-id-390, .page-id-391, .page-id-392, .page-id-396, .page-id-397, .page-id-398, .page-id-402, .page-id-403, .page-id-404))) {
    font-size: 16px;
  }
}

@media (max-width: 767px) {

  /* ----------------------------------------------------------
     1 · INTERLINEADO
     ---------------------------------------------------------- */
  .la-content p, .la-content li,
  [class*="-prose"] p, [class*="-prose"] li { line-height: 1.65; }
  [class*="-chips"] > li,
  [class*="-flow"] > li,
  [class*="-stages"] > li,
  [class*="-questions"] > li,
  [class*="-kit"] > li,
  [class*="-art21"] > li,
  [class*="-path"] > li,
  [class*="-order"] > li,
  [class*="-trace"] > li,
  [class*="-rulechain"] > li,
  [class*="-quotes"] > li { line-height: 1.55; }

  /* ----------------------------------------------------------
     2 · TEXTO DE LECTURA EN TARJETAS Y LISTAS → 15 px
     (descripciones, extractos, notas, celdas de tabla densas)
     ---------------------------------------------------------- */
  .lacomp-matrix__note,
  .lacm-comp-col__tagline,
  .laar-step__desc,
  .lais-loss-item__note,
  .lais-r-value-box__note,
  .lais-pros li, .lais-cons li,
  .lapm-mat-card__detalle,
  .lapm-profile-code__hint,
  .lasn-pillar__desc,
  .lawf-house-card__desc,
  .lawf-wall-layer__desc,
  .lawf-tech-img__note,
  .la-check-hint,
  .la-compare-col__note,
  .la-maker-card__note,
  .p2-acero-card__list li,
  .p2-model-card__text,
  .p2-project-card__text,
  .p2-type-card__desc,
  .p4-wall-diagram-note,
  .p4-profile-table td,
  .p5-ed-note,
  .p5-vi__d,
  .sfco-meta li,
  .sfcop-meta li,
  .laco-hero__meta li,
  .sfco-table td,
  .sfcop-table td,
  .sfcop-bands__note,
  .sfcop-check__score p { font-size: 15px; }

  /* ----------------------------------------------------------
     3 · TEXTO SECUNDARIO → 14 px
     (fechas, meta, fuentes, CTA de tarjeta, etiquetas de fila,
     pills de tipo, badges sin mayúsculas, leyendas, pie)
     ---------------------------------------------------------- */
  /* (el pie tiene sus tamaños en footer.css desde el rediseño del 29/9) */
  /* migas */
  .lact-breadcrumb, .lact-breadcrumb a, .lact-breadcrumb__current,
  .labl-breadcrumb a, .labl-breadcrumb span,
  .lahome-hero-breadcrumbs a, .lahome-hero-breadcrumbs span,
  .p2-breadcrumb__inner a, .p2-breadcrumb__current,
  .p4-breadcrumb__inner a, .p4-breadcrumb__current,
  .p5-bc__i a, .p5-bc__cur,
  .laco-breadcrumbs a, .laco-breadcrumbs span,
  .sfco-breadcrumbs a, .sfco-breadcrumbs span,
  .sfcop-breadcrumbs a, .sfcop-breadcrumbs span,
  /* posts (content.css) */
  .lact-post-header__meta-item, .lact-post-header__meta-item time,
  .lact-related-card__date,
  /* hub de steel framing (tarjetas de país con clases .lahome-) */
  .lahome-country-card a,
  .lahome-country-card__norma,
  .lahome-country-card__precio,
  /* tarjetas de guías / posts de los pilares */
  .lahome-pillar-card__tag, .lahome-pillar-card__cta,
  .ladw-guide-card__tag, .ladw-guide-card__cta,
  .lacr-guide-card__tag, .lacr-guide-card__cta,
  .lacm-guide-card__tag, .lacm-guide-card__cta,
  .lais-guide-card__tag, .lais-guide-card__cta,
  .lapm-guide-card__tag, .lapm-guide-card__cta,
  .larv-guide-card__tag, .larv-guide-card__cta,
  .lawf-pillar-card__tag, .lawf-pillar-card__cta,
  .lacomp-article-card__tag, .lacomp-article-card__cta,
  .labl-post-card__date time, .labl-post-card__read,
  .lahome-post-card__date, .lahome-post-card__read,
  .ladw-post-card__date, .ladw-post-card__read,
  .lacr-post-card__date, .lacr-post-card__read,
  .larv-post-card__date, .larv-post-card__read,
  /* badges del hero sin mayúsculas */
  .lahome-hero__badge, .ladw-hero__badge, .lacr-hero__badge,
  .lacm-hero__badge, .lais-hero__badge, .lapm-hero__badge,
  .larv-hero__badge, .laar-hero__badge, .lacomp-hero__badge,
  .lawf-hero__badge,
  .lasn-hero__meta-item,
  .p2-hero__meta-item, .p4-hero__meta-item, .p5-hero__mi,
  /* fuentes (bloque trust) */
  .lahome-trust__source, .ladw-trust__source, .lacr-trust__source,
  .lacm-trust__source, .lais-trust__source, .lapm-trust__source,
  .larv-trust__source, .laar-trust__source, .lacomp-trust__source,
  .lawf-trust__source, .sfcop-source__link,
  /* pills de tipos */
  .ladw-type-pill__name, .ladw-type-pill__use,
  .lacr-type-pill, .lacr-type-pill__name, .lacr-type-pill__use,
  .larv-type-pill, .larv-type-pill__name, .larv-type-pill__use,
  .lacm-tipo-pill__name, .lacm-tipo-pill__use,
  /* navegación interna de los heros / subnav */
  .lais-hero__navlink, .lapm-hero__navlink,
  .laar-hero__quicklink, .laar-sticky-bar__link,
  .lawf-subnav__link,
  .labl-filter__btn, .lapm-mat-tab, .lais-mat-tab,
  /* aislación */
  .lais-house-diagram__caption, .lais-lambda-bar__legend span,
  .lais-r-item__label, .lais-r-item__val,
  .lais-r-value-box__note a, .lais-r-value-box__note strong,
  .lais-r-value-box__title,
  .lais-tva-card__metric-label, .lais-tva-card__metric-val,
  .lais-wall-diagram__title, .lais-wall-layer__label, .lais-wall-layer__sub,
  .lalan-ruler__axis span,
  /* ampliaciones / modular / comparativas */
  .laar-service__tag,
  .lacm-comp-col__badge, .lacm-preview__img-badge,
  .lacomp-matrix__cell, .lacomp-matrix__stars,
  /* placas y materiales */
  .lapm-spec-key, .lapm-spec-val, .lapm-mat-card__codigo,
  .lapm-pros-mini__item, .lapm-cons-mini__item,
  .lasn-source__desc, .p4-layer-item__desc, .p4-source-item__desc, .p5-src__d,
  /* sobre nosotros / contacto */
  .lasn-agency-card__link, .lasn-person-card__link, .lasn-trust-item__label,
  .lac-field label, .lac-field a, .lac-info-item__label,
  /* wood frame */
  .lawf-house-card__sup, .lawf-house-card__plantas,
  .lawf-projects-img__badge, .lawf-split__img-caption,
  .lawf-wall-photo__caption, .lawf-tech-img__note strong,
  /* plantillas p2 / p4 / p5 / la- (posts de steel framing) */
  .p2-cta__link-title, .p2-split__caption,
  .p4-cta__link-title, .p4-wall-diagram-wrap__head-sub,
  .p5-bdg, .p5-cta__lt, .p5-ed-head__s, .p5-ed-li span,
  .p5-step__tag, .p5-tc__rd,
  .la-profile-card__code, .la-profile-card__use, .la-use-item__code,
  .laes-db__rule sub, .sfge-table sub,
  /* Colombia (escala propia) */
  .laco-hero__meta time, .laco-swipe, .laco-tabla caption, .laco-tabla .marca,
  .sfco-meta time, .sfco-norma__ref, .sfco-obra__score span,
  .sfco-oferta__nota, .sfco-pull footer, .sfco-swipe,
  .sfco-table caption, .sfco-table th,
  .sfcop-band__caption, .sfcop-band__caption strong, .sfcop-band__usd,
  .sfcop-bands__tick, .sfcop-calc__foot, .sfcop-calc__foot strong,
  .sfcop-calc__out b, .sfcop-calc__out em, .sfcop-calc__trm, .sfcop-calc__trm strong,
  .sfcop-card__figure small, .sfcop-check__wrap th, .sfcop-figure figcaption,
  .sfcop-meta time, .sfcop-pull footer, .sfcop-swipe,
  .sfcop-table a, .sfcop-table caption, .sfcop-table th, .sfcop-table .num strong { font-size: 14px; }

  .la-btn, .la-skip-link { font-size: 15px; }

  /* Tarjetas de posts: el título (display, .9375rem = 15 px) sube a
     17 px y el extracto va a 14 px, así se mantiene la jerarquía. */
  .labl-post-card__title, .lahome-post-card__title, .ladw-post-card__title,
  .lacr-post-card__title, .larv-post-card__title { font-size: 17px; }
  .labl-post-card__excerpt, .lahome-post-card__excerpt, .ladw-post-card__excerpt,
  .lacr-post-card__excerpt, .larv-post-card__excerpt,
  .lacomp-article-card__excerpt { font-size: 14px; line-height: 1.55; }

  /* ----------------------------------------------------------
     4 · ETIQUETAS EN MAYÚSCULAS → 12 px (se mantiene el
     letter-spacing de cada plantilla)
     ---------------------------------------------------------- */
  .lahome-eyebrow, .ladw-eyebrow, .lacr-eyebrow, .lacm-eyebrow,
  .lais-eyebrow, .lapm-eyebrow, .larv-eyebrow, .laar-eyebrow,
  .lacomp-eyebrow, .lawf-eyebrow, .laco-eyebrow, .sfco-eyebrow, .sfcop-eyebrow,
  .lasn-hero__eyebrow, .lact-cta__eyebrow, .la-checklist-eyebrow, .la-when-card__eyebrow,
  .p2-hero__eyebrow, .p2-cta__eyebrow, .p2-model-card__eyebrow, .p2-project-card__eyebrow,
  .p4-hero__eyebrow, .p4-cta__eyebrow, .p5-hero__ey, .p5-cta__ey,
  .lahome-trust__label, .ladw-trust__label, .lacr-trust__label, .lacm-trust__label,
  .lais-trust__label, .lapm-trust__label, .larv-trust__label, .laar-trust__label,
  .lacomp-trust__label, .lawf-trust__label,
  .ladw-types-strip__label, .lacr-types-strip__label, .larv-types-strip__label,
  .lacm-tipos-strip__label,
  .labl-post-card__cat, .lahome-post-card__cat, .ladw-post-card__cat,
  .lacr-post-card__cat, .larv-post-card__cat, .lacomp-article-card__cat,
  .lacomp-article-card__badge, .lacomp-factor-card__tag,
  .lacomp-matrix__head .lacomp-matrix__cell,
  .lact-post-header__cat,
  .laar-service__eyebrow-label, .laar-service__priority,
  .lacm-hub-card__badge,
  .lais-ac-level__badge, .lais-lambda-display__label,
  .lasn-agency-card__role, .lasn-person-card__role,
  .lawf-wall-layer__side,
  .la-comp-badge, .la-compare-col__label, .la-maker-card__country,
  .la-nom-item__label, .la-profile-card__use-label, .la-tag,
  .la-thickness-table th,
  .p2-acero-card__tag, .p2-cta__link-label, .p2-gallery__item-label, .p2-plano-block__badge,
  .p4-badge, .p4-cta__link-label, .p4-snippet__label,
  .p4-profile-table th, .p4-summary-table th,
  .p5-cta__ll, .p5-scen th, .p5-snip__lbl, .p5-tc__rl,
  .laco-cat__tag, .laco-hero__flag, .laco-norma__tag, .laco-region__clima,
  .sfco-card__tag, .sfco-norma__tag, .sfco-oferta__tag, .sfco-tags li,
  .sfcop-card__tag, .sfcop-tags li, .sfcop-answer__label, .sfcop-method dt,
  .sfco-meta li > span:first-child, .sfcop-meta li > span:first-child,
  .sfcop-calc__out > span { font-size: 12px; }

  /* ----------------------------------------------------------
     4b · Selectores más específicos de las plantillas
     ---------------------------------------------------------- */
  /* Tarjetas de país del hub de steel framing (clases .lahome-,
     escala en px). La home ya no usa estas clases: su legibilidad
     móvil vive en assets/home.css (rediseño 29/9/2026). */
  .lahome-country-card p { font-size: 14px; line-height: 1.5; }
  .p4-summary-table thead th,
  .p4-profile-table thead th,
  .p5-scen thead th { font-size: 12px; }
  .sfcop-check thead th.co { font-size: 14px; }
  .sfcop-card .sfcop-card__figure small { font-size: 14px; }

  /* ----------------------------------------------------------
     4c · Componentes con <style> dentro del contenido del post
     (perfiles PGC, vs construcción tradicional): ese <style>
     va en el <body> y gana por orden, así que se sube la
     especificidad con "html body".
     ---------------------------------------------------------- */
  html body .la-check-hint,
  html body .la-maker-card__note,
  html body .la-compare-col__note { font-size: 15px; }
  html body .la-profile-card__code,
  html body .la-profile-card__use,
  html body .la-use-item__code { font-size: 14px; }
  html body .la-checklist-eyebrow,
  html body .la-comp-badge,
  html body .la-compare-col__label,
  html body .la-maker-card__country,
  html body .la-nom-item__label,
  html body .la-profile-card__use-label,
  html body .la-tag,
  html body .la-when-card__eyebrow,
  html body .la-thickness-table thead th { font-size: 12px; }

  /* Pie de tarjetas de guía: con los tags a 14 px la fila
     "tags + Leer →" se apretaba; se permite el salto de línea. */
  .lahome-pillar-card__footer, .ladw-guide-card__footer, .lacr-guide-card__footer,
  .lacm-guide-card__footer, .lais-guide-card__footer, .lapm-guide-card__footer,
  .larv-guide-card__footer, .lawf-pillar-card__footer,
  .lacomp-article-card__footer { flex-wrap: wrap; gap: 10px; }

  /* ----------------------------------------------------------
     5 · OBJETIVOS TÁCTILES
     ---------------------------------------------------------- */
  /* 5a · enlaces y botones sueltos → caja de 44 px */
  .la-btn,
  .lahome-country-card > a,
  .lahome-what__link, .ladw-what__link, .lacr-what__link, .larv-what__link,
  .labl-post-card__read, .lahome-post-card__read, .ladw-post-card__read,
  .lacr-post-card__read, .larv-post-card__read,
  .lacomp-article-card__cta,
  .lahome-trust__source, .ladw-trust__source, .lacr-trust__source,
  .lacm-trust__source, .lais-trust__source, .lapm-trust__source,
  .larv-trust__source, .laar-trust__source, .lacomp-trust__source,
  .lawf-trust__source, .sfcop-source__link,
  .lais-hero__navlink, .lapm-hero__navlink,
  .laar-hero__quicklink, .laar-sticky-bar__link,
  .lasn-agency-card__link, .lasn-person-card__link,
  [class*="-more"] > a,
  [class*="-sources"] > a,
  [class*="-facts__list"] a,
  [class*="-words__list"] a,
  table[class*="--stack"] a,
  .sfcop-table th a, .sfcop-table td a {
    display: inline-flex; align-items: center; min-height: 44px;
  }
  /* categoría de la tarjeta / del post: etiqueta-enlace en mayúsculas */
  .labl-post-card__cat { display: inline-flex; align-items: center; min-height: 44px; }
  .lact-post-header__cat { display: flex; align-items: center; width: fit-content; min-height: 44px; margin-bottom: .25rem; }

  /* 5b · botones de filtro, pestañas, chips y toggles */
  .labl-filter__btn, .lacomp-filter__btn, .lapm-filter__btn,
  .lapm-mat-tab, .lais-mat-tab,
  .lawf-subnav__link,
  .lacr-type-pill--cta, .larv-type-pill--cta,
  .la-pagination .page-numbers,
  [class*="faq__item"] > summary,
  [class*="faq__trigger"], [class*="faq__btn"],
  [class*="toc__summary"], [class*="tocm__btn"], [class*="toc-mobile__toggle"],
  #toc-mobile-btn {
    min-height: 44px;
  }
  .labl-filter__btn, .lacomp-filter__btn, .lapm-filter__btn,
  .lapm-mat-tab, .lais-mat-tab, .lawf-subnav__link {
    display: inline-flex; align-items: center; justify-content: center;
  }
  .la-pagination .page-numbers { min-width: 44px; display: inline-flex; align-items: center; justify-content: center; }

  /* 5c · migas: 36 px para no inflar el hero (WCAG 2.5.8 pide 24) */
  nav[class*="breadcrumb"] a,
  [class*="breadcrumb__inner"] a,
  .p5-bc__i a {
    display: inline-flex; align-items: center; min-height: 36px; min-width: 32px;
  }

  /* 5d · índices (TOC): filas de 44 px y 8 px entre enlaces */
  [class*="toc__list"] a,
  [class*="toc-list"] a,
  [class*="tocm__list"] a,
  [class*="toc__ul"] a,
  #lact-toc-list a {
    display: flex; align-items: center; min-height: 44px;
  }

  /* 5e · pie: objetivos de 44 px en assets/footer.css (rediseño del 29/9) */

  /* 5f · los enlaces dentro de párrafos NO se agrandan (excepción
     de WCAG 2.5.8 para enlaces en línea): solo se asegura el
     interlineado >= 1.5 del bloque 1. */
}
