.platform-home {
  --home-ink: #202b33;
  --home-muted: #53616d;
  --home-line: #dce3e7;
  --home-accent: var(--platform-interactive, #176c77);
  background: #f8fafb;
}

.mh-home {
  padding: 0 0 1.5rem;
  color: var(--home-ink);
  font-family: system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
}
.mh-home a { color: inherit; text-decoration: none; }
.mh-home a:hover { color: var(--home-accent); text-decoration: underline; text-underline-offset: .2em; }
.mh-home :focus-visible,
.mh-home .platform-filters input:focus-visible + span { outline: 2px solid var(--home-accent); outline-offset: 3px; }

.mh-hero {
  display: grid;
  justify-items: center;
  padding: clamp(.4rem, .75vw, .75rem) 0 .5rem;
}
.mh-intro { width: min(100%, 43rem); text-align: center; }
.mh-intro h1 {
  margin: 0;
  font-size: clamp(1.65rem, 2.8vw, 2.25rem);
  font-weight: 730;
  line-height: 1.2;
  text-wrap: balance;
}
.mh-intro-copy { margin: .35rem 0 .65rem; color: var(--home-muted); text-wrap: balance; }
.mh-home .platform-search { --platform-accent: var(--home-accent); margin-inline: auto; }
.mh-home .platform-search-fields input { border-color: #85949e; }
.mh-home .platform-search-fields button { font-weight: 650; }
.mh-home .platform-filters { justify-content: center; gap: .18rem .32rem; }
.mh-home .platform-filters span { border-color: transparent; background: transparent; min-height: 44px; padding-inline: .6rem; }
.mh-home .platform-filters label:hover span { color: var(--home-accent); }
.mh-home .platform-filters input:checked + span {
  background: #e8f2f3;
  color: #155761;
  border-color: transparent;
  font-weight: 650;
}
.mh-directory {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr));
  gap: .85rem;
  margin-block-start: .8rem;
  font-size: .9rem;
}
.mh-directory > section, .mh-moments {
  min-width: 0;
  background: #fff;
  border: 1px solid var(--home-line);
  border-radius: 9px;
  padding: .62rem .85rem;
}
.mh-directory > .mh-map { background: #f3f8f8; }
.mh-directory h2, .mh-moments h2, .mh-photos h2 { margin: 0; line-height: 1.25; font-size: 1.12rem; }
.mh-directory h2 a, .mh-photos h2 a { display: flex; align-items: center; justify-content: space-between; min-height: 35px; gap: .5rem; }
.mh-directory h2 span, .mh-photos h2 span { color: var(--home-accent); font-size: .9rem; }
.mh-map-description { margin: 0 0 .5rem; color: var(--home-muted); }
.mh-index h3 { margin: .15rem 0 .25rem; font-size: .82rem; color: var(--home-muted); font-weight: 600; }
.mh-places, .mh-records { padding: 0; margin: 0; list-style: none; }
.mh-places li + li, .mh-records li + li { border-block-start: 1px solid var(--home-line); }
.mh-places a, .mh-records a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: .5rem;
  min-height: 37px;
  padding-block: .22rem;
  overflow-wrap: anywhere;
}
.mh-places small, .mh-records small, .mh-count { color: var(--home-muted); font-size: .78rem; }
.mh-places small, .mh-records small { text-align: end; }
.mh-count { display: inline-flex; align-items: center; min-height: 28px; }

.mh-moments-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: .35rem .7rem;
  margin-block-end: .55rem;
}
.mh-moments h2 small { color: var(--home-muted); font-size: .74em; white-space: nowrap; }
.mh-moments-controls { display: flex; align-items: center; gap: .18rem; }
.mh-moments [hidden] { display: none; }
.mh-moments-controls button {
  display: grid;
  place-items: center;
  width: 35px;
  height: 35px;
  padding: 0;
  border: 1px solid var(--home-line);
  border-radius: 5px;
  background: #f7fafb;
  color: var(--home-accent);
  cursor: pointer;
  font: 1.35rem/1 system-ui, sans-serif;
}
.mh-moments-controls button:hover { background: #eaf3f4; }
.mh-moments-controls [data-moments-count] { min-width: 2.65rem; text-align: center; font-size: .79rem; font-variant-numeric: tabular-nums; }
[dir="rtl"] .mh-moments-controls [data-step] span { transform: scaleX(-1); }
.mh-toggle-icon { width: 10px; height: 12px; border-inline: 3px solid currentColor; }
[data-paused="true"] .mh-toggle-icon { width: 0; height: 0; border-inline-start: 9px solid currentColor; border-inline-end: 0; border-block: 6px solid transparent; }

.mh-slides { display: grid; }
.mh-moment {
  grid-area: 1 / 1;
  display: grid;
  grid-template-columns: minmax(0, 1.23fr) minmax(0, 1fr);
  gap: clamp(.7rem, 2vw, 1.5rem);
  align-items: center;
  min-width: 0;
}
.mh-moment--compact-photo { grid-template-columns: minmax(0, 1.07fr) minmax(0, 1fr); }
.mh-moment[hidden] { display: grid; visibility: hidden; pointer-events: none; }
.mh-moment-media { display: grid; place-items: center; margin: 0; min-width: 0; }
.mh-moment-copy { min-width: 0; }
.mh-moment-image { display: block; max-width: 100%; }
.mh-moment-image img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: clamp(225px, 25vw, 334px);
  border-radius: 5px;
}
.mh-moment-copy .mh-moment-credit {
  font-size: .73rem;
  color: var(--home-muted);
  overflow-wrap: anywhere;
}
.mh-moment-credit a { text-decoration: underline; }
.mh-location {
  position: relative;
  border: 1px solid var(--home-line);
  border-radius: 6px;
  overflow: hidden;
}
.mh-location-map {
  display: block;
  aspect-ratio: 512 / 156;
  position: relative;
  background: #eaf1f2;
  overflow: hidden;
}
.mh-location-tiles { position: absolute; inset: 0; }
.mh-location-tiles img {
  position: absolute;
  width: calc(100% * 256 / 512 + .3px);
  height: calc(100% * 256 / 156 + .3px);
  max-width: none;
  filter: saturate(.65);
}
.mh-location-map svg { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
.mh-location-point { fill: #176c77; stroke: #fff; stroke-width: 2.5; }
.mh-location-point--subject { fill: #fff; stroke: #176c77; }
.mh-location-area { fill: #497d8f40; stroke: #176c77; stroke-width: 2; stroke-dasharray: 5 3; }
.mh-location-map--unavailable svg, .mh-location-map--unavailable .mh-location-tiles { display: none; }
.mh-location-unavailable { position: absolute; inset: 0; display: grid; place-items: center; font-size: .86rem; }
.mh-location .mh-location-credit {
  position: absolute;
  inset-inline-end: 0;
  inset-block-end: 0;
  background: #fffffff2;
  padding: .05rem .25rem;
  color: #32444b;
  font-size: .64rem;
}
.mh-moment-copy h3 { font-size: clamp(1.15rem, 2vw, 1.5rem); margin: 0; line-height: 1.2; overflow-wrap: anywhere; }
.mh-moment-copy p { margin: .3rem 0; overflow-wrap: anywhere; }
.mh-moment-meta { font-size: .8rem; color: var(--home-muted); }
.mh-moment-summary {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: .91rem;
}
.mh-moment-place { font-size: .84rem; }
.mh-moment-place small { color: var(--home-muted); margin-inline-start: .35rem; }
.mh-moment-links { display: flex; align-items: center; flex-wrap: wrap; gap: 0 .65rem; }
.mh-moment-links a { display: inline-flex; min-height: 40px; align-items: center; font-size: .84rem; }
.mh-moment-links .mh-map-action { color: var(--home-accent); font-weight: 700; }

.mh-photos { margin-block-start: 1rem; border-block-start: 1px solid var(--home-line); padding-block-start: .4rem; }
.mh-photos figure { margin: 0; font-size: .86rem; }
.mh-photos figure > a { display: inline-flex; align-items: center; gap: .65rem; }
.mh-photos img { display: block; width: 92px; height: 57px; object-fit: cover; border-radius: 4px; }
.mh-photos figcaption { color: var(--home-muted); font-size: .75rem; margin-block-start: .2rem; }

@media (max-width: 750px) {
  .mh-directory { gap: .7rem; }
  .mh-moment { grid-template-columns: minmax(0, 1fr); gap: .55rem; }
  .mh-moment-image img { max-height: min(66vw, 285px); }
  .mh-location-map { min-height: 94px; }
  .mh-moments-controls button { width: 44px; height: 44px; }
  .mh-moment-links a, .mh-places a, .mh-records a, .mh-count, .mh-directory h2 a { min-height: 44px; }
}
@media (max-width: 560px) {
  .mh-intro-copy { font-size: .91rem; }
  .mh-home .platform-search-fields { gap: .4rem; }
  .mh-home .platform-search-fields button { padding-inline: .7rem; }
  .mh-home .platform-filters { gap: 0; padding-block-start: .35rem; }
  .mh-home .platform-filters span { padding-inline: .45rem; font-size: .79rem; }
}
