/* Small utilities share the existing page-language row. */
.h2-page-tools {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: none;
}
.h2-header-tools {
  display: inline-flex;
  align-items: center;
  gap: 0;
  margin: 0;
  padding-right: 8px;
  border-right: 1px solid #d6dfe3;
  color: var(--ink, #1c3445);
}
.h2-header-tools .h2-tool-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: inherit;
  background: transparent;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .15s ease;
}
.h2-tool-icon svg { display: block; width: 14px; height: 14px; flex: none; }
.h2-header-tools .h2-tool-icon:hover { background: #edf1f2; }
.h2-tool-icon:focus-visible, .h2-search-dialog button:focus-visible, .h2-search-result-link:focus-visible {
  outline: 2px solid #315b71;
  outline-offset: 2px;
}
.h2-search-dialog {
  position: fixed;
  box-sizing: border-box;
  width: min(420px, calc(100vw - 24px));
  max-width: 420px;
  max-height: min(480px, calc(100dvh - 24px));
  inset: 12px auto auto 12px;
  margin: 0;
  padding: 16px;
  border: 1px solid #dce3e5;
  border-radius: 6px;
  background: #fff;
  color: #1c3445;
  box-shadow: 0 8px 32px #122b4124;
  font: inherit;
  overflow: auto;
  overscroll-behavior: contain;
}
.h2-search-dialog::backdrop { background: #14263118; }
.h2-search-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.h2-search-title { margin: 0; color: #1c3445; font-family: inherit; font-size: 16px; font-weight: 600; line-height: 1.5; }
.h2-search-close {
  display: grid;
  flex: 0 0 32px;
  place-items: center;
  width: 32px;
  height: 32px;
  margin: -5px -6px -5px 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #526774;
  cursor: pointer;
}
.h2-search-close:hover { background: #f0f3f4; color: #1c3445; }
.h2-search-close svg { width: 18px; height: 18px; }
.h2-search-form { margin: 0; }
.h2-search-label { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.h2-search-field { display: flex; align-items: center; gap: 8px; padding: 0 11px; border: 1px solid #bbcbd2; border-radius: 4px; background: #fff; }
.h2-search-field:focus-within { border-color: #315b71; box-shadow: 0 0 0 2px #315b7112; }
.h2-search-field > svg { width: 17px; height: 17px; flex: 0 0 17px; color: #526774; }
.h2-search-dialog .h2-search-input {
  display: block;
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  height: 44px;
  margin: 0;
  padding: 0;
  border: 0;
  outline: 0;
  border-radius: 0;
  background: transparent;
  color: #1c3445;
  font: inherit;
  font-size: 16px;
  box-shadow: none;
}
.h2-search-input::placeholder { color: #74838b; opacity: 1; font-size: 13px; }
.h2-search-retry[hidden], .h2-search-status:empty { display: none; }
.h2-search-retry {
  border: 1px solid #dde5e8;
  border-radius: 4px;
  padding: 7px 11px;
  background: #f7f9fa;
  color: #344e5d;
  font: inherit;
  font-size: 12px;
  line-height: 1.5;
  cursor: pointer;
}
.h2-search-retry:hover { border-color: #abbfc8; background: #edf3f5; }
.h2-search-status { margin: 12px 0 8px; color: #657680; font-size: 12px; line-height: 1.6; }
.h2-search-results { list-style: none; padding: 0; margin: 0; }
.h2-search-result { margin: 0; padding: 0; border-top: 1px solid #e8edef; }
.h2-search-result-link { display: block; padding: 11px 8px; margin: 0 -8px; border-radius: 4px; color: #1c3445; text-decoration: none; }
.h2-search-result-link:hover { background: #f5f8f9; }
.h2-search-category { display: block; margin-bottom: 3px; color: #627e8e; font-size: 10px; line-height: 1.4; letter-spacing: .3px; }
.h2-search-result-title { display: block; font-size: 14px; font-weight: 600; line-height: 1.6; }
.h2-search-result-summary { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; margin-top: 3px; color: #697a84; font-size: 12px; line-height: 1.6; }
@media (max-width: 640px) {
  .h2-header-tools .h2-tool-icon { width: 36px; height: 36px; }
  .h2-tool-icon svg { width: 15px; height: 15px; }
  .article-topline { flex-wrap: wrap; gap: 8px; }
  .article-topline .breadcrumb { flex: 1 1 160px; }
  .article-topline .h2-page-tools { margin-left: auto; }
  .h2-search-close { width: 36px; height: 36px; flex-basis: 36px; }
}
@media (prefers-reduced-motion: reduce) {
  .h2-header-tools .h2-tool-icon { transition: none; }
}
