/* ALLHIR Round71 / 2.39.39
 * Exact Community-style rounded typography and single-column legacy blog media.
 * This regression correction contains no layout changes outside blog media.
 */

:root{
  --ah-community-font:ui-rounded,"SF Pro Rounded","Avenir Next Rounded","Avenir Next","Trebuchet MS",system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}

/* Use the same rounded face as the ALLHIR Community display language.
 * Keep icon fonts untouched by targeting text-bearing elements only. */
body,
body .site-header,
body main,
body .site-footer,
body .sidebar-menu,
body .allhir-account-dropdown{
  font-family:var(--ah-community-font)!important;
  font-optical-sizing:auto;
}
body .site-header :is(a,button,input,select,span,small,strong,b),
body main :is(h1,h2,h3,h4,h5,h6,p,a,button,input,textarea,select,option,label,legend,summary,dt,dd,li,span,small,strong,b,time),
body .site-footer :is(a,button,input,select,span,small,strong,b,p,li),
body .sidebar-menu :is(a,button,span,small,strong,b),
body .allhir-account-dropdown :is(a,button,span,small,strong,b){
  font-family:var(--ah-community-font)!important;
}

/* Community heading is the platform-wide reference: rounded, substantial,
 * but without condensed or synthetic legacy faces. */
body main h1,
body main h2,
body main h3,
body main h4,
body main h5,
body main h6,
body main [class*="__title"],
body main [class*="__heading"]{
  font-family:var(--ah-community-font)!important;
  font-weight:800!important;
  font-stretch:normal!important;
  letter-spacing:-.025em;
}
body main h1{font-weight:850!important}
body main p,
body main li,
body main dd{
  font-weight:500!important;
  font-stretch:normal!important;
}
body main button,
body main [role="button"],
body main nav a,
body main [class*="__btn"],
body main [class*="__more"]{
  font-weight:750!important;
  font-stretch:normal!important;
}

/* Remove WordPress' legacy left/right floats which produced the desktop
 * checkerboard. Standalone article images now form one calm centred column. */
body:not(#allhir-never) main .allhir-single-post__text .alignleft,
body:not(#allhir-never) main .allhir-single-post__text .alignright,
body:not(#allhir-never) main .allhir-single-post__text .aligncenter,
body:not(#allhir-never) main .allhir-single-post__text figure.alignleft,
body:not(#allhir-never) main .allhir-single-post__text figure.alignright,
body:not(#allhir-never) main .allhir-single-post__text figure.aligncenter,
body:not(#allhir-never) main .allhir-single-post__text p:has(img){
  position:static!important;
  display:block!important;
  float:none!important;
  clear:both!important;
  width:100%!important;
  max-width:720px!important;
  margin:clamp(24px,4vw,38px) auto!important;
  inset:auto!important;
  text-align:center!important;
}
body:not(#allhir-never) main .allhir-single-post__text p:has(img) > a,
body:not(#allhir-never) main .allhir-single-post__text figure > a{
  display:block!important;
  width:100%!important;
  max-width:100%!important;
  margin:0 auto!important;
}
body:not(#allhir-never) main .allhir-single-post__text img.alignleft,
body:not(#allhir-never) main .allhir-single-post__text img.alignright,
body:not(#allhir-never) main .allhir-single-post__text img.aligncenter,
body:not(#allhir-never) main .allhir-single-post__text p:has(img) img{
  position:static!important;
  display:block!important;
  float:none!important;
  clear:both!important;
  width:100%!important;
  max-width:720px!important;
  height:auto!important;
  margin:0 auto!important;
  inset:auto!important;
}

/* A real WordPress gallery remains a gallery; only unrelated floated images
 * are converted to the centred single-column reading flow. */
body:not(#allhir-never) main .allhir-single-post__text .wp-block-gallery,
body:not(#allhir-never) main .allhir-single-post__text .gallery{
  max-width:800px!important;
  margin-inline:auto!important;
}
body:not(#allhir-never) main .allhir-single-post__text .wp-block-gallery figure,
body:not(#allhir-never) main .allhir-single-post__text .gallery-item{
  max-width:none!important;
  margin:0!important;
}

@media(max-width:760px){
  body:not(#allhir-never) main .allhir-single-post__text .alignleft,
  body:not(#allhir-never) main .allhir-single-post__text .alignright,
  body:not(#allhir-never) main .allhir-single-post__text .aligncenter,
  body:not(#allhir-never) main .allhir-single-post__text p:has(img),
  body:not(#allhir-never) main .allhir-single-post__text img.alignleft,
  body:not(#allhir-never) main .allhir-single-post__text img.alignright,
  body:not(#allhir-never) main .allhir-single-post__text img.aligncenter,
  body:not(#allhir-never) main .allhir-single-post__text p:has(img) img{
    max-width:100%!important;
  }
}
