/* Article / setup-guide template (.mb-hero, .mt-*) — reuses the .mh design system. */

/* ---------- Hero ---------- */
body .mh.mb-hero { position: relative; overflow: hidden; isolation: isolate; background: var(--mode-ink); color: #fff; padding: calc(var(--mh-header) + 72px) 0 88px; }
body .mh.mb-hero::before {
  content: ""; position: absolute; z-index: -1; inset: 0; opacity: 1; border-radius: 0;
  background: radial-gradient(46% 70% at 80% 40%, rgba(0, 85, 164, .3), rgba(0, 85, 164, 0) 70%),
    radial-gradient(30% 40% at 8% 100%, rgba(143, 178, 242, .08), rgba(143, 178, 242, 0) 70%);
}
body .mh.mb-hero::after {
  content: ""; position: absolute; z-index: -1; top: var(--mh-header); right: -60px; bottom: -40px; width: 220px;
  background: var(--mode-navy-card); opacity: .55; transform: skewX(-14deg);
}
body .mh.mt-hero--post.has-image { padding-bottom: 152px; }
body .mh .mb-hero__inner { display: flex; flex-direction: column; gap: 22px; }
body .mh .mb-hero__inner > * { max-width: 820px !important; }
body .mh .mb-eyebrow .elementor-heading-title { color: var(--mode-sky); }
body .mh .mb-eyebrow .elementor-heading-title::before { background: var(--mode-sky); }
body .mh.mb-hero h1.elementor-heading-title { font-size: 54px; line-height: 1.05; letter-spacing: -.015em; color: #fff; }
body .mh .mb-crumbs ol { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 0; margin: 0; padding: 0; list-style: none; font-size: 14px; line-height: 1.4; }
body .mh .mb-crumbs li { display: flex; align-items: center; color: #c4cde3; }
body .mh .mb-crumbs li + li::before {
  content: ""; width: 6px; height: 6px; margin: 0 12px; border-top: 1.5px solid #6c80aa; border-right: 1.5px solid #6c80aa; transform: rotate(45deg);
}
body .mh .mb-crumbs a { color: #fff; font-weight: 600; text-decoration: none; }
body .mh .mb-crumbs a:hover { color: var(--mode-sky); text-decoration: underline; }
body .mh .mb-crumbs [aria-current] { color: var(--mode-sky); font-weight: 600; }
body .mh .mt-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 26px; margin: 4px 0 0; padding: 0; list-style: none; font-size: 15px; line-height: 1.4; color: #c4cde3; }
body .mh .mt-meta li { display: flex; align-items: center; gap: 8px; margin: 0; }
body .mh .mt-meta__date::before, body .mh .mt-meta__time::before { content: ""; width: 18px; height: 18px; background: var(--mode-sky); }
body .mh .mt-meta__date::before {
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='17' rx='2'/%3E%3Cpath d='M3 9h18M8 2v4M16 2v4'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='17' rx='2'/%3E%3Cpath d='M3 9h18M8 2v4M16 2v4'/%3E%3C/svg%3E") center / contain no-repeat;
}
body .mh .mt-meta__time::before {
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7v5l3 2'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7v5l3 2'/%3E%3C/svg%3E") center / contain no-repeat;
}
body .mh .mt-avatar {
  width: 32px; height: 32px; border-radius: 50%; border: 2px solid #22325e; background: var(--mode-blue); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 800;
}
body .mh .mt-meta a { color: #fff; font-weight: 700; text-decoration: none; }
body .mh .mt-meta a:hover { color: var(--mode-sky); text-decoration: underline; }
@media (max-width: 1024px) {
  body .mh.mb-hero { padding: calc(var(--mh-header) + 56px) 0 64px; }
  body .mh.mt-hero--post.has-image { padding-bottom: 112px; }
  body .mh.mb-hero h1.elementor-heading-title { font-size: 44px; }
  body .mh.mb-hero::after { display: none; }
}
@media (max-width: 640px) {
  body .mh.mb-hero { padding: calc(var(--mh-header) + 36px) 0 48px; }
  body .mh.mt-hero--post.has-image { padding-bottom: 88px; }
  body .mh.mb-hero h1.elementor-heading-title { font-size: 34px; line-height: 1.08; }
  body .mh .mb-hero__inner { gap: 18px; }
}

/* ---------- Article layout ---------- */
body .mh.mt-article { padding: 0 0 var(--mode-section-pad); background: #fff; }
body .mh .mt-featured { position: relative; z-index: 2; margin: -112px auto 56px !important; max-width: 1120px !important; width: 100%; }
body .mh .mt-featured img {
  display: block; width: 100%; height: auto; max-height: 560px; object-fit: cover;
  border-radius: var(--mode-radius-band); box-shadow: 0 30px 60px -30px rgba(7, 18, 48, .45);
}
body .mh .mt-layout { display: grid !important; grid-template-columns: minmax(0, 760px) 320px; justify-content: center; gap: 56px; align-items: start; }
@media (max-width: 1100px) { body .mh .mt-layout { grid-template-columns: minmax(0, 760px); } }
@media (max-width: 1024px) { body .mh .mt-featured { margin: -80px auto 44px !important; } }
@media (max-width: 640px) {
  body .mh .mt-featured { margin: -60px auto 36px !important; }
  body .mh .mt-featured img { border-radius: 16px; }
}

/* ---------- Prose (one native widget per block) ---------- */
body .mh .mt-prose { display: block !important; min-width: 0; max-width: 780px; font-size: 17px; line-height: 1.75; color: var(--mode-text-2); }
body .mh .mt-prose > .elementor-widget + .elementor-widget { margin-top: 20px !important; }
body .mh .mt-prose > .elementor-widget.mt-h2 { margin-top: 52px !important; }
body .mh .mt-prose > .elementor-widget.mt-h3 { margin-top: 36px !important; }
body .mh .mt-prose > .elementor-widget:first-child { margin-top: 0 !important; }
body .mh .mt-prose > :is(.mt-h2, .mt-h3) + .elementor-widget { margin-top: 14px !important; }
body .mh .mt-prose > .elementor-widget + .mt-fig { margin-top: 32px !important; }
body .mh .mt-prose .elementor-heading-title { font-family: var(--mode-font-display); font-weight: 700; color: var(--mode-text); scroll-margin-top: calc(var(--mh-header) + 16px); }
body .mh .mt-prose .mt-h2 .elementor-heading-title { font-size: 32px; line-height: 1.15; letter-spacing: -.01em; }
body .mh .mt-prose .mt-h3 .elementor-heading-title { font-size: 23px; line-height: 1.25; }
body .mh .mt-prose strong { color: var(--mode-text); font-weight: 700; }
body .mh .mt-prose a { color: var(--mode-blue); font-weight: 600; text-decoration: underline 1px; text-underline-offset: 3px; }
body .mh .mt-prose a:hover { color: var(--mode-blue-hover); text-decoration-thickness: 2px; }
body .mh .mt-prose :is(ul, ol) { margin: 0; padding-left: 0; }
body .mh .mt-prose .mt-list ul { list-style: none; }
body .mh .mt-prose .mt-list ul > li { position: relative; padding-left: 26px; }
body .mh .mt-prose .mt-list ul > li::before {
  content: ""; position: absolute; left: 6px; top: .72em; width: 7px; height: 7px; border-radius: 2px; background: var(--mode-blue); transform: rotate(45deg);
}
body .mh .mt-prose .mt-list ol { list-style: none; counter-reset: mt-ol; }
body .mh .mt-prose .mt-list ol > li { position: relative; padding-left: 38px; counter-increment: mt-ol; }
body .mh .mt-prose .mt-list ol > li::before {
  content: counter(mt-ol); position: absolute; left: 0; top: .15em; width: 26px; height: 26px; border-radius: 50%;
  background: var(--mode-tint); color: var(--mode-blue); font-size: 13px; font-weight: 800; line-height: 26px; text-align: center;
}
body .mh .mt-prose li + li { margin-top: 10px; }
body .mh .mt-prose .mt-fig img { display: block; height: auto; max-width: 100%; border-radius: 14px; }
body .mh .mt-prose .mt-fig:not(.mt-fig--natural) img { width: 100%; }
body .mh .mt-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 44px 0 0; padding: 24px 0 0; border-top: 1px solid var(--mode-line); list-style: none; }
body .mh .mt-prose .mt-tags > li { margin: 0; padding: 0; }
body .mh .mt-tags a {
  display: block; padding: 8px 14px; border-radius: 999px; background: var(--mode-chip); color: var(--mode-text-2);
  font-size: 13px; font-weight: 700; line-height: 1.3; text-decoration: none;
}
body .mh .mt-tags a:hover { background: #dde7f8; color: var(--mode-blue-hover); }
@media (max-width: 640px) {
  body .mh .mt-prose { font-size: 16px; }
  body .mh .mt-prose > .elementor-widget.mt-h2 { margin-top: 40px !important; }
  body .mh .mt-prose .mt-h2 .elementor-heading-title { font-size: 26px; }
  body .mh .mt-prose .mt-h3 .elementor-heading-title { font-size: 20px; }
}

/* ---------- Sidebar ---------- */
body .mh .mt-sidebar { position: sticky; top: calc(var(--mh-header) + 24px); display: flex; flex-direction: column; gap: 20px; min-width: 0; }
body .mh .mt-widget { padding: 24px; background: var(--mode-paper); border: 1px solid var(--mode-line); border-radius: var(--mode-radius-card); }
body .mh .mt-widget__title { margin-bottom: 16px !important; }
body .mh .mt-widget__title .elementor-heading-title {
  font-family: var(--mode-font-display); font-size: 14px; font-weight: 700; line-height: 1.2; letter-spacing: .12em; text-transform: uppercase; color: var(--mode-blue);
}
body .mh .mt-search { position: relative; margin: 0; }
body .mh .mt-search__field {
  width: 100%; height: 48px; margin: 0; padding: 0 48px 0 14px; border: 1px solid #d3dcef; border-radius: 12px; background: #fff;
  color: var(--mode-text); font-family: var(--mode-font-body); font-size: 15px; box-shadow: none;
}
body .mh .mt-search__field:focus { outline: 0; border-color: var(--mode-blue); box-shadow: 0 0 0 3px rgba(0, 85, 164, .16); }
body .mh .mt-search__btn {
  position: absolute; top: 4px; right: 4px; width: 40px; height: 40px; margin: 0; padding: 0; display: flex; align-items: center; justify-content: center;
  border: 0; border-radius: 10px; background: var(--mode-blue); color: #fff; cursor: pointer;
}
body .mh .mt-search__btn:hover { background: var(--mode-blue-hover); color: #fff; }
body .mh .mt-cats { margin: 0; padding: 0; list-style: none; }
body .mh .mt-cats li { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0; padding: 10px 0; border-top: 1px solid var(--mode-line); font-size: 15px; line-height: 1.4; }
body .mh .mt-cats li:first-child { border-top: 0; padding-top: 0; }
body .mh .mt-cats a { color: var(--mode-text-2); font-weight: 600; text-decoration: none; }
body .mh .mt-cats a:hover { color: var(--mode-blue); }
body .mh .mt-tagcloud { display: flex; flex-wrap: wrap; gap: 8px; }
body .mh .mt-tagcloud a {
  margin: 0; padding: 6px 12px; border: 1px solid var(--mode-line); border-radius: 999px; background: #fff; color: var(--mode-text-2);
  font-size: 13px; font-weight: 600; line-height: 1.3; text-decoration: none;
}
body .mh .mt-tagcloud a:hover { border-color: var(--mode-blue); color: var(--mode-blue); }
@media (max-width: 1100px) {
  body .mh .mt-sidebar { position: static; display: grid !important; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  body .mh .mt-widget--tags { grid-column: 1 / -1; }
}
@media (max-width: 640px) { body .mh .mt-sidebar { grid-template-columns: minmax(0, 1fr); } }

/* Tables (comparison / troubleshooting) */
body .mh .mt-prose > .elementor-widget + .mt-table-w { margin-top: 32px !important; }
body .mh .mt-table { overflow: auto; border: 1px solid var(--mode-line); border-radius: 16px; }
body .mh .mt-table table { width: 100%; margin: 0; border: 0; border-collapse: collapse; background: #fff; font-size: 13px; line-height: 1.5; }
body .mh .mt-table td { padding: 12px 16px; border: 0; border-bottom: 1px solid var(--mode-line); text-align: left; vertical-align: top; background: none; }
body .mh .mt-table tr:last-child td { border-bottom: 0; }
/* header row is a <thead> with <th> (accessibility) — looks exactly like the former first <td> row */
body .mh .mt-table th { padding: 12px 16px; border: 0; border-bottom: 1px solid var(--mode-line); background: none; text-align: left; vertical-align: top; font-weight: 700; color: var(--mode-text); }
body .mh .mt-table th:first-child { width: 150px; }
body .mh .mt-table tbody tr td { background: none; }
body .mh .mt-table tr:nth-child(2n) td { background: none; }
body .mh .mt-table td:first-child { font-weight: 700; color: var(--mode-text); width: 150px; }
/* theme paragraphs in the reference use 1.8 line-height (lists keep 1.75) */
body .mh .mt-prose .mt-p { line-height: 1.8; }

/* Archive / hub hero lead */
body .mh .mb-hero__lead { font-size: 17px; line-height: 1.7; color: #c4cde3; }
body .mh .mh-post__title a { color: inherit; text-decoration: none; }
body .mh.mb-list .mh-grid { gap: 24px; }

/* Legal / plain pages: centered 820px prose */
body .mh .mt-prose.mt-prose--page { max-width: 820px; margin-inline: auto; }

/* Pagination (blog index) */
body .mh .mb-pages ul { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px; margin: 0; padding: 0; list-style: none; }
body .mh .mb-pages li { margin: 0; }
body .mh .mb-pages .page-numbers {
  display: inline-flex; align-items: center; justify-content: center; min-width: 48px; height: 48px; padding: 0 14px;
  border: 1px solid var(--mode-line); border-radius: var(--mode-radius-btn); background: #fff; color: var(--mode-text-2);
  font-size: 15px; font-weight: 700; line-height: 1; text-decoration: none; transition: border-color .2s, color .2s;
}
body .mh .mb-pages a.page-numbers:hover { border-color: var(--mode-blue); color: var(--mode-blue); }
body .mh .mb-pages .page-numbers.current { background: var(--mode-blue); border-color: var(--mode-blue); color: #fff; }
body .mh .mb-pages .page-numbers.dots { border: 0; background: none; min-width: auto; padding: 0 4px; }
/* Blog template markup (no Elementor widget wrappers) */
body .mh.mb-hero .mh-eyebrow p, body .mh .mh-post__meta, body .mh .mh-post__excerpt { margin: 0; }
body .mh .mh-post__img img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
body .mh .mh-post__more { margin: auto 24px 0; }

/* ---------- Search form, search results & 404 (mh-home/search.php, 404.php) ---------- */
body .mh .mb-search { display: flex; gap: 10px; max-width: 620px !important; width: 100%; margin-top: 6px; }
body .mh .mb-search input[type=search] {
  flex: 1; min-width: 0; height: 54px; padding: 0 18px; border: 1px solid rgba(255,255,255,.22); border-radius: 12px;
  background: rgba(255,255,255,.08); color: #fff; font: 500 16px/1 var(--mode-font-body, inherit);
}
body .mh .mb-search input[type=search]::placeholder { color: rgba(255,255,255,.6); }
body .mh .mb-search input[type=search]:focus { outline: 2px solid var(--mode-sky); outline-offset: 1px; background: rgba(255,255,255,.12); }
body .mh .mb-search button {
  height: 54px; padding: 0 24px; border: 0; border-radius: 12px; background: var(--mode-blue); color: #fff;
  font: 700 16px/1 var(--mode-font-body, inherit); cursor: pointer; transition: background .2s;
}
body .mh .mb-search button:hover { background: var(--mode-blue-hover); }
body .mh .mb-help { display: flex; flex-direction: column; gap: 20px; }
body .mh .mb-help__title { margin: 0; font-family: var(--mode-font-display); font-size: 30px; font-weight: 700; color: var(--mode-text); }
body .mh .mb-help__list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; }
body .mh .mb-help__list a {
  display: flex; flex-direction: column; gap: 6px; height: 100%; padding: 20px 22px; border: 1px solid var(--mode-line); border-radius: 14px;
  background: #fff; color: var(--mode-text-2); text-decoration: none; transition: border-color .2s, box-shadow .2s, transform .2s;
}
body .mh .mb-help__list a:hover { border-color: var(--mode-blue); box-shadow: 0 14px 30px -18px rgba(7,18,48,.35); transform: translateY(-2px); }
body .mh .mb-help__list strong { color: var(--mode-blue); font-size: 18px; font-weight: 700; }
body .mh .mb-help__list span { font-size: 15px; line-height: 1.5; }
@media (max-width: 1024px) { body .mh .mb-help__list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 767px) {
  body .mh .mb-help__list { grid-template-columns: 1fr; }
  body .mh .mb-help__title { font-size: 24px; }
  body .mh .mb-search { flex-direction: column; }
  body .mh .mb-search input[type=search] { flex: none; width: 100%; }
  body .mh .mb-search button { width: 100%; }
}

/* Touch: sidebar category links fill their row (≥40px tap area) instead of the text line only. */
@media (max-width: 1024px) {
  body .mh .mt-cats li { padding: 0; }
  body .mh .mt-cats li:first-child { padding-top: 0; }
  body .mh .mt-cats a { flex: 1; display: block; padding: 10px 0; }
}
@media (max-width: 1024px) { body .mh .mt-tagcloud a { min-height: 36px; display: inline-flex; align-items: center; } }
