/* Minimal layout repairs around the recovered June 2023 MH Magazine Lite design. */
@import url('/fonts/open-sans.css');

/* Prevent box-model overflow on narrow viewports while preserving desktop widths. */
.mh-container, .mh-container-inner, .mh-wrapper, .mh-site-logo, .mh-content, .mh-sidebar, .mh-copyright-wrap {
  box-sizing: border-box;
}

/* Keep navigation visible on narrow screens without requiring obsolete SlickNav/jQuery JS. */
.mh-header-mobile-nav { display: none !important; }
#mh-mobile .mh-main-nav, .mh-main-nav { display: block !important; }
.mh-main-nav ul { display: flex; flex-wrap: wrap; }
.mh-main-nav li { float: none; }

/* Frame homepage & archive thumbnails consistently to match the original 326x245 / 235px float layout. */
.mh-loop-thumb img { aspect-ratio: 326 / 245; object-fit: cover; height: auto; }

/* Accessible keyboard focus indicators matching MH Magazine Lite accent red. */
a:focus-visible, button:focus-visible { outline: 2px solid #e64946; outline-offset: 2px; }

/* Unrecovered internal links without href stay visually quiet while keeping text intact. */
a:not([href]) { color: inherit; cursor: default; text-decoration: none; }
a:not([href]):hover { color: inherit; text-decoration: none; }

/* Pre-2016 legacy content cleanly styled inside the June 2023 WordPress content column. */
.legacy-archive-article { line-height: 1.65; overflow-wrap: anywhere; }
.legacy-archive-article img { max-width: 100%; height: auto; }
.legacy-archive-article table { width: 100%; border-collapse: collapse; margin: 14px 0; }
.legacy-archive-article td, .legacy-archive-article th { padding: 6px 8px; border: 1px solid #e5e5e5; vertical-align: top; }

/* Ensure WordPress content images and captions never overflow mobile viewports. */
.entry-content img { max-width: 100%; height: auto; }
.entry-content { overflow-wrap: anywhere; }
.wp-caption { max-width: 100% !important; }

/* Image viewer lightbox dialog */
.lightbox { border: 2px solid #2a2a2a; padding: 12px; background: #fff; max-width: 92vw; max-height: 92vh; }
.lightbox::backdrop { background: rgb(0 0 0 / 75%); }
.lightbox img { display: block; max-width: 86vw; max-height: 80vh; object-fit: contain; }
.lightbox button { display: block; margin: 0 0 8px auto; padding: 6px 12px; background: #2a2a2a; color: #fff; border: 0; cursor: pointer; font-size: 13px; }
.lightbox button:hover { background: #e64946; }

/* Standalone 404 / error page layout */
.standalone-error { max-width: 720px; margin: 40px auto; padding: 28px; background: #fff; border-top: 4px solid #e64946; box-shadow: 0 1px 4px rgb(0 0 0 / 8%); }

@media (max-width: 767px) {
  .mh-main-nav li a { padding: 10px 12px; font-size: 12px; white-space: normal; }
  #mh-mobile .mh-header-title { font-size: 20px; line-height: 1.2; overflow-wrap: break-word; }
  #mh-mobile .mh-header-tagline { font-size: 12px; line-height: 1.3; }
  #mh-mobile .mh-wrapper, #mh-mobile .mh-site-logo { padding: 15px; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
}
