.hm-page {
  background: var(--color-pale-luminescence);
}

.hm-page .hm-section {
  padding-block: var(--space-9);
}

.hm-page .hm-section__header {
  min-width: 0;
}

.hm-page .hm-section__header p:last-child {
  margin-block-end: 0;
}

.hm-hero {
  position: relative;
  overflow: hidden;
  padding-block: var(--space-8) var(--space-9);
}

.hm-hero::after,
.hm-next::after {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(120deg, transparent 0 48%, rgba(110, 158, 157, 0.06) 48.1% 48.4%, transparent 48.5% 100%);
  content: "";
}

.hm-hero__layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 52fr) minmax(0, 48fr);
  align-items: center;
  gap: var(--space-7);
}

.hm-hero__layout > * { min-width: 0; }

.hm-hero__copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
  gap: var(--space-4);
}

.hm-hero__copy > * { min-width: 0; margin: 0; }

.hm-hero h1 { max-width: 650px; color: var(--color-pale-luminescence); }
.hm-hero .lead { max-width: 760px; font-size: var(--text-lead); line-height: var(--leading-lead); }
.hm-hero__scope { max-width: 700px; }

.hm-route-rule { display: flex; align-items: center; width: 160px; min-width: 0; gap: 8px; }
.hm-route-rule span { display: block; flex: 1 1 0; height: 1px; background: var(--color-ancient-teal); }
.hm-route-rule i { display: block; flex: 0 0 8px; width: 8px; height: 8px; border: 1px solid var(--color-ancient-teal); border-radius: 50%; }

.hm-hero__meta { display: flex; flex-wrap: wrap; min-width: 0; gap: var(--space-3); color: var(--color-ancient-teal); font-family: var(--font-mono); font-size: var(--text-micro); letter-spacing: .045em; line-height: var(--leading-micro); }
.hm-hero__meta span { min-width: 0; }

.hm-spoiler-note { max-width: 720px; padding: var(--space-3) var(--space-4); border-inline-start: 2px solid var(--color-faded-amethyst); background: var(--color-cavern-slate); color: var(--color-pale-luminescence); font-size: var(--text-meta); line-height: var(--leading-meta); }
.hm-spoiler-note strong { color: var(--color-ancient-teal); }

.hm-anchor-nav { display: flex; flex-wrap: wrap; min-width: 0; gap: var(--space-3) var(--space-5); }
.hm-anchor-nav a { color: var(--color-pale-luminescence); font-family: var(--font-mono); font-size: var(--text-micro); text-transform: uppercase; }

.hm-hero__media { width: 100%; min-width: 0; margin: 0; }
.hm-hero__media img { width: 100%; height: auto; aspect-ratio: 16 / 7; object-fit: cover; object-position: 70% center; border: 1px solid rgba(181, 155, 114, .8); }
.hm-hero__media figcaption { color: var(--color-ancient-teal); }

.hm-reading { padding-block-start: var(--space-10); }
.hm-section__header--measure { width: min(100%, 680px); }
.hm-terrain-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 3fr); align-items: start; gap: var(--space-6); margin-block-start: var(--space-7); }
.hm-terrain-grid > * { min-width: 0; }
.hm-jump-note { min-width: 0; max-width: 660px; }
.hm-original-diagram { position: relative; width: 100%; height: 180px; overflow: hidden; margin-block-end: var(--space-4); border-block: 1px solid var(--color-relic-bronze); background: rgba(110, 158, 157, .12); }
.hm-platform { position: absolute; bottom: 34px; display: block; height: 14px; background: var(--color-cavern-slate); }
.hm-platform--start { left: 8%; width: 30%; }
.hm-platform--end { right: 8%; width: 28%; }
.hm-jump-arc { position: absolute; bottom: 47px; left: 28%; width: 47%; height: 95px; border-top: 2px dashed var(--color-ancient-teal); border-radius: 50% 50% 0 0; transform: rotate(-4deg); }
.hm-diagram-dot { position: absolute; top: 41px; left: 49%; width: 10px; height: 10px; border-radius: 50%; background: var(--color-faded-amethyst); }
.hm-terrain-aside { display: flex; flex-direction: column; min-width: 0; gap: var(--space-5); }
.hm-terrain-aside > * { min-width: 0; }
.hm-margin-note { padding-inline-start: var(--space-4); border-inline-start: 1px solid var(--color-relic-bronze); }
.hm-return-note { padding: var(--space-5); background: var(--color-cavern-slate); color: var(--color-pale-luminescence); }
.hm-return-note h3 { color: var(--color-pale-luminescence); }

.hm-progression { border-block: 1px solid var(--color-relic-bronze); background: rgba(110, 158, 157, .08); }
.hm-section__header--progression { width: min(100%, 680px); }
.hm-progression__layout { display: grid; grid-template-columns: minmax(0, 72fr) minmax(290px, 28fr); align-items: stretch; gap: var(--space-5); margin-block-start: var(--space-7); }
.hm-progression__layout > * { min-width: 0; }
.hm-route-map { position: relative; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); align-items: center; min-height: 300px; min-width: 0; gap: var(--space-3); padding: var(--space-5); border: 1px solid var(--color-cavern-slate); background: var(--color-pale-luminescence); }
.hm-route-map__line { position: absolute; z-index: 0; top: 50%; right: 9%; left: 9%; height: 2px; background: var(--color-ancient-teal); }
.hm-skill-node { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; width: 100%; min-width: 0; min-height: 104px; padding: var(--space-3); border: 1px solid var(--color-cavern-slate); background: var(--color-pale-luminescence); color: var(--color-abyssal-ink); text-align: left; }
.hm-skill-node span { overflow-wrap: anywhere; font-family: var(--font-heading); font-size: 1.45rem; line-height: 1; }
.hm-skill-node small { margin-block-start: var(--space-2); color: var(--color-text-muted); font-family: var(--font-mono); font-size: .65rem; line-height: 1.3; }
.hm-skill-node.is-active, .hm-skill-node[aria-pressed="true"] { border: 2px solid var(--color-ancient-teal); background: var(--color-cavern-slate); color: var(--color-pale-luminescence); }
.hm-skill-node.is-active::before { position: absolute; top: -10px; left: 50%; width: 10px; height: 10px; border-radius: 50%; background: var(--color-ancient-teal); content: ""; transform: translateX(-50%); }
.hm-skill-node.is-active small { color: var(--color-ancient-teal); }
.hm-skill-panel { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; gap: var(--space-4); padding: var(--space-5); border-block-start: 2px solid var(--color-faded-amethyst); background: var(--color-cavern-slate); color: var(--color-pale-luminescence); }
.hm-skill-panel > * { min-width: 0; margin: 0; }
.hm-skill-panel h3 { color: var(--color-pale-luminescence); }

.hm-skill-feature { display: grid; grid-template-columns: minmax(0, 7fr) minmax(330px, 5fr); align-items: start; gap: var(--space-7); }
.hm-skill-feature > * { min-width: 0; }
.hm-skill-feature__copy { width: min(100%, 640px); }
.hm-action-label { display: inline-block; margin-block-end: var(--space-3); padding: 3px 6px; border: 1px solid var(--color-relic-bronze); color: var(--color-abyssal-ink); font-family: var(--font-mono); font-size: var(--text-micro); line-height: 1.2; }
.hm-field-note { display: flex; flex-direction: column; min-width: 0; gap: var(--space-3); margin-block-start: var(--space-6); padding: var(--space-4); background: var(--color-cavern-slate); color: var(--color-pale-luminescence); }
.hm-field-note > * { min-width: 0; margin: 0; }
.hm-skill-feature__media { width: 100%; min-width: 0; margin: 0; }
.hm-skill-feature__media img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border: 1px solid var(--color-relic-bronze); }
.hm-description-toggle { width: auto; margin-block-start: var(--space-3); border-color: var(--color-cavern-slate); background: transparent; color: var(--color-link); }
.hm-description-toggle:hover { background: var(--color-cavern-slate); color: var(--color-pale-luminescence); }
.hm-expanded-description { margin-block: var(--space-3) 0; padding: var(--space-3); border-inline-start: 2px solid var(--color-ancient-teal); background: rgba(110, 158, 157, .12); font-size: var(--text-meta); }

.hm-vertical { background: rgba(181, 155, 114, .08); }
.hm-section__header--vertical { width: min(100%, 760px); }
.hm-vertical__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: stretch; gap: var(--space-5); margin-block-start: var(--space-7); }
.hm-vertical__grid > * { min-width: 0; }
.hm-vertical-card { display: grid; grid-template-columns: minmax(0, 40fr) minmax(0, 60fr); min-width: 0; gap: var(--space-5); padding: var(--space-5); border: 1px solid var(--color-cavern-slate); }
.hm-vertical-card > * { min-width: 0; }
.hm-vertical-card__copy { min-width: 0; }
.hm-wall-diagram, .hm-wing-diagram { position: relative; min-width: 0; min-height: 210px; border-block: 1px solid var(--color-relic-bronze); }
.hm-wall-diagram span, .hm-wall-diagram b { position: absolute; top: 14%; bottom: 14%; display: block; width: 18px; background: var(--color-cavern-slate); }
.hm-wall-diagram span { left: 8%; }.hm-wall-diagram b { right: 8%; }
.hm-wall-diagram i { position: absolute; top: 24%; left: 35%; width: 35%; height: 58%; border-right: 2px dashed var(--color-ancient-teal); border-bottom: 2px dashed var(--color-ancient-teal); border-radius: 0 0 55% 0; transform: skewY(-20deg); }
.hm-wing-diagram span { position: absolute; right: 7%; bottom: 20%; width: 40%; height: 13px; background: var(--color-pale-luminescence); }
.hm-wing-diagram i { position: absolute; bottom: 31%; left: 17%; width: 55%; height: 95px; border-top: 2px dashed var(--color-faded-amethyst); border-radius: 50% 50% 0 0; }
.hm-wing-diagram b { position: absolute; top: 31%; left: 48%; width: 12px; height: 12px; border-radius: 50%; background: var(--color-ancient-teal); }
.hm-combination-note { width: min(100%, 760px); margin-block-start: var(--space-6); padding-block-start: var(--space-5); border-block-start: 1px solid var(--color-relic-bronze); }

.hm-section__header--special { width: min(100%, 760px); }
.hm-special__grid { display: grid; grid-template-columns: minmax(0, 8fr) minmax(340px, 4fr); align-items: start; gap: var(--space-6); margin-block-start: var(--space-7); }
.hm-special__grid > * { min-width: 0; }
.hm-heart-panel { min-width: 0; }
.hm-heart-panel__copy { width: min(100%, 620px); }
.hm-heart-panel__media { position: relative; width: 100%; min-width: 0; margin: var(--space-5) 0 0; }
.hm-heart-panel__media img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border: 1px solid var(--color-relic-bronze); }
.hm-heart-route { position: absolute; top: 49%; left: 12%; width: 67%; height: 2px; background: var(--color-ancient-teal); transform: rotate(-3deg); }
.hm-heart-route::after { position: absolute; top: -4px; right: -1px; width: 9px; height: 9px; border-top: 2px solid var(--color-ancient-teal); border-right: 2px solid var(--color-ancient-teal); content: ""; transform: rotate(45deg); }
.hm-tear-panel { min-width: 0; padding: var(--space-5); border-block-start: 2px solid var(--color-faded-amethyst); background: rgba(142, 131, 180, .12); }
.hm-caution-note { display: flex; flex-direction: column; min-width: 0; gap: var(--space-3); margin-block-start: var(--space-6); padding: var(--space-5); }
.hm-caution-note > * { min-width: 0; margin: 0; }
.hm-caution-note p:last-child { width: min(100%, 680px); }

.hm-obstacles { border-block: 1px solid var(--color-relic-bronze); }
.hm-section__header--obstacles { width: min(100%, 680px); }
.hm-obstacle-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: stretch; margin-block-start: var(--space-7); border-block: 1px solid var(--color-cavern-slate); }
.hm-obstacle-grid > * { min-width: 0; }
.hm-obstacle-item { min-width: 0; padding: var(--space-5); border-inline-end: 1px solid var(--color-cavern-slate); }
.hm-obstacle-item:last-child { border-inline-end: 0; }

.hm-section__header--return { width: min(100%, 760px); }
.hm-return__grid { display: grid; grid-template-columns: minmax(0, 8fr) minmax(300px, 4fr); align-items: start; gap: var(--space-7); margin-block-start: var(--space-7); }
.hm-return__grid > * { min-width: 0; }
.hm-steps { width: min(100%, 760px); }
.hm-steps ol { display: flex; flex-direction: column; min-width: 0; gap: var(--space-4); margin: 0; padding: 0; list-style: none; counter-reset: steps; }
.hm-steps li { position: relative; min-width: 0; padding-inline-start: 52px; counter-increment: steps; }
.hm-steps li::before { position: absolute; top: -5px; left: 0; color: var(--color-relic-bronze); content: counter(steps, decimal-leading-zero); font-family: var(--font-heading); font-size: 2rem; line-height: 1; }
.hm-checklist { display: flex; flex-direction: column; min-width: 0; gap: var(--space-3); padding: var(--space-5); background: var(--color-cavern-slate); color: var(--color-pale-luminescence); }
.hm-checklist > * { min-width: 0; margin: 0; }
.hm-checklist h3 { color: var(--color-pale-luminescence); }
.hm-checklist button { justify-content: flex-start; width: 100%; min-height: 44px; border-color: rgba(220, 232, 231, .55); background: transparent; color: var(--color-pale-luminescence); text-align: left; }
.hm-checklist button[aria-expanded="true"] { border-color: var(--color-ancient-teal); background: rgba(110, 158, 157, .18); }
.hm-checklist button + p { padding-inline-start: var(--space-3); border-inline-start: 2px solid var(--color-ancient-teal); color: var(--color-pale-luminescence); font-size: var(--text-meta); }
.hm-deepen-links { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); align-items: start; gap: var(--space-5); margin-block-start: var(--space-7); padding-block-start: var(--space-5); border-block-start: 2px solid var(--color-ancient-teal); }
.hm-deepen-links > * { min-width: 0; }
.hm-deepen-links h3 { font-family: var(--font-body); font-size: var(--text-body); line-height: 1.35; }
.hm-deepen-links p { font-size: var(--text-meta); line-height: var(--leading-meta); }

.hm-faq { background: rgba(110, 158, 157, .08); }
.hm-faq__inner { width: min(100%, 900px); }
.hm-section__header--faq { width: min(100%, 680px); }
.hm-faq-list { margin-block-start: var(--space-6); border-block-start: 1px solid var(--color-cavern-slate); }
.hm-faq-item { min-width: 0; border-block-end: 1px solid var(--color-cavern-slate); }
.hm-faq-item h3 { margin: 0; }
.hm-faq-item h3 button { justify-content: space-between; width: 100%; min-height: 58px; padding: var(--space-3) 0; border: 0; border-radius: 0; background: transparent; color: var(--color-abyssal-ink); font-family: var(--font-body); font-size: var(--text-body); text-align: left; }
.hm-faq-item h3 button::after { flex: 0 0 auto; margin-inline-start: var(--space-4); color: var(--color-ancient-teal); content: "+"; font-family: var(--font-mono); font-size: 1.35rem; }
.hm-faq-item h3 button[aria-expanded="true"]::after { content: "−"; }
.hm-faq-item > div { width: min(100%, 660px); margin-inline-start: var(--space-7); }
.hm-faq-item > div p { margin-block-end: var(--space-5); }

.hm-next { position: relative; overflow: hidden; padding-block: var(--space-9); }
.hm-next .container { position: relative; z-index: 1; }
.hm-next__content { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; gap: var(--space-4); width: min(100%, 680px); }
.hm-next__content > * { min-width: 0; margin: 0; }
.hm-next__content h2 { color: var(--color-pale-luminescence); }
.hm-next__actions { display: flex; flex-wrap: wrap; min-width: 0; gap: var(--space-3); margin-block-start: var(--space-2); }
.hm-next__actions > * { min-width: 0; }
.hm-next__secondary { border-color: var(--color-pale-luminescence); background: transparent; color: var(--color-pale-luminescence); }
.hm-next__secondary:hover { border-color: var(--color-pale-luminescence); background: var(--color-pale-luminescence); color: var(--color-abyssal-ink); }

@media (max-width: 68.75rem) {
  .hm-hero__layout { grid-template-columns: 1fr; gap: var(--space-6); }
  .hm-hero__copy { width: min(100%, 760px); }
  .hm-hero__media img { aspect-ratio: 16 / 8; }
  .hm-progression__layout { grid-template-columns: 1fr; }
  .hm-skill-panel { width: min(100%, 520px); }
}

@media (max-width: 61.25rem) {
  .hm-skill-feature { grid-template-columns: 1fr; gap: var(--space-6); }
  .hm-skill-feature__copy { width: min(100%, 680px); }
  .hm-skill-feature__media { width: min(100%, 720px); }
  .hm-special__grid { grid-template-columns: 1fr; }
  .hm-tear-panel { width: min(100%, 560px); }
  .hm-return__grid { grid-template-columns: 1fr; gap: var(--space-6); }
  .hm-checklist { width: min(100%, 760px); }
  .hm-deepen-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 58.125rem) {
  .hm-terrain-grid { grid-template-columns: 1fr; }
  .hm-terrain-aside { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-5); }
  .hm-vertical__grid { grid-template-columns: 1fr; }
  .hm-obstacle-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hm-obstacle-item:nth-child(2) { border-inline-end: 0; }
  .hm-obstacle-item:nth-child(3) { grid-column: 1 / -1; border-inline-end: 0; border-block-start: 1px solid var(--color-cavern-slate); }
}

@media (max-width: 47.9375rem) {
  .hm-page .hm-section { padding-block: var(--space-8); }
  .hm-hero { padding-block: var(--space-7); }
  .hm-hero h1 { font-size: clamp(2.75rem, 12vw, 3.5rem); }
  .hm-hero__layout { gap: var(--space-5); }
  .hm-hero__media img { aspect-ratio: 16 / 9; object-position: 68% center; }
  .hm-terrain-aside { grid-template-columns: 1fr; }
  .hm-route-map { display: flex; flex-direction: column; align-items: stretch; min-height: 0; gap: var(--space-3); padding: var(--space-4); }
  .hm-route-map__line { top: 9%; bottom: 9%; left: 28px; width: 2px; height: auto; }
  .hm-skill-node { min-height: 48px; padding-inline-start: 44px; }
  .hm-skill-node.is-active::before { top: 50%; left: 21px; transform: translate(-50%, -50%); }
  .hm-vertical-card { grid-template-columns: 1fr; gap: var(--space-4); }
  .hm-wall-diagram, .hm-wing-diagram { min-height: 170px; }
  .hm-obstacle-grid { grid-template-columns: 1fr; }
  .hm-obstacle-item, .hm-obstacle-item:nth-child(2), .hm-obstacle-item:nth-child(3) { grid-column: auto; border-inline-end: 0; border-block-start: 1px solid var(--color-cavern-slate); }
  .hm-obstacle-item:first-child { border-block-start: 0; }
  .hm-deepen-links { grid-template-columns: 1fr; }
  .hm-faq-item > div { width: 100%; margin-inline-start: 0; }
  .hm-next { padding-block: 3.5rem; }
  .hm-next__actions { flex-direction: column; width: 100%; }
  .hm-next__actions .button { width: 100%; }
}

@media (max-width: 38.75rem) {
  .hm-hero__meta { flex-direction: column; align-items: flex-start; gap: var(--space-2); }
  .hm-spoiler-note { padding: var(--space-3); }
  .hm-next__content { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .hm-page * { scroll-behavior: auto; }
}
