.skip-link {
  position: fixed;
  z-index: 100;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  background: var(--ho-indigo);
  color: var(--ho-paper-raised);
  font-family: var(--ho-font-ui);
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

main {
  overflow: clip;
}

.place-banner {
  position: relative;
  min-height: clamp(224px, 23vw, 278px);
  overflow: hidden;
  border-bottom: 1px solid var(--ho-line-strong);
  background: var(--ho-paper-light);
  isolation: isolate;
}

.place-banner figure,
.place-banner figure::after {
  position: absolute;
  z-index: -2;
  inset: 0;
  margin: 0;
}

.place-banner figure::after {
  z-index: 1;
  background:
    linear-gradient(90deg, var(--ho-paper-light) 0%, color-mix(in srgb, var(--ho-paper-light) 98%, transparent) 34%, color-mix(in srgb, var(--ho-paper-light) 70%, transparent) 56%, color-mix(in srgb, var(--ho-paper-light) 8%, transparent) 84%),
    linear-gradient(0deg, rgba(24, 49, 57, 0.2), transparent 46%);
  content: "";
}

.place-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 64% 51%;
  filter: sepia(0.03) saturate(0.76) contrast(0.93);
  transform: scale(1.01);
}

.place-banner figcaption {
  position: absolute;
  z-index: 2;
  right: var(--ho-gutter);
  bottom: 13px;
  color: rgba(246, 251, 249, 0.9);
  font-family: var(--ho-font-ui);
  font-size: 0.7rem;
  letter-spacing: 0.01em;
}

.place-banner-copy {
  width: min(var(--ho-content-max), calc(100% - (var(--ho-gutter) * 2)));
  margin: 0 auto;
  padding: clamp(28px, 4vw, 46px) 0;
}

.back-link {
  color: var(--ho-indigo);
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-ui);
  font-weight: 640;
  text-decoration: none;
}

.back-link:hover,
.back-link:focus-visible {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.place-trail {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
  color: var(--ho-ink-muted);
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-meta);
}

.place-trail a {
  color: var(--ho-indigo);
  cursor: pointer;
  text-decoration-color: var(--ho-line-strong);
  text-underline-offset: 3px;
}

.place-banner h1 {
  margin: clamp(24px, 3vw, 36px) 0 0;
  font-size: var(--ho-type-page-title);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: var(--ho-leading-display);
}

.place-why {
  max-width: 62ch;
  margin: 12px 0 0;
  color: var(--ho-ink-muted);
  font-size: var(--ho-type-body);
  line-height: 1.55;
}

.place-banner h1 span {
  display: inline-block;
  margin-left: 0.24em;
  color: var(--ho-ink-muted);
  font-size: 0.38em;
  letter-spacing: 0;
  vertical-align: 0.35em;
}

.place-reading-grid {
  display: grid;
  width: min(calc(var(--ho-content-max) + (var(--ho-gutter) * 2)), 100%);
  grid-template-columns: minmax(0, 1.82fr) minmax(330px, 0.9fr);
  margin: 0 auto;
  align-items: stretch;
}

.today-guide {
  min-width: 0;
  padding: clamp(38px, 4.5vw, 58px) var(--ho-gutter) clamp(58px, 7vw, 82px);
}

.guide-mode-label { margin-bottom: 0; }

.historical-context {
  min-width: 0;
  padding: clamp(38px, 4.5vw, 58px) clamp(26px, 3vw, 42px) clamp(58px, 7vw, 82px);
  background:
    repeating-linear-gradient(20deg, color-mix(in srgb, var(--ho-ink) 1.65%, transparent) 0, color-mix(in srgb, var(--ho-ink) 1.65%, transparent) 1px, transparent 1px, transparent 8px),
    linear-gradient(
      90deg,
      var(--ho-coastal-page) 0,
      color-mix(in srgb, var(--ho-coastal-page) 54%, var(--ho-historical-paper-light)) 42px,
      var(--ho-historical-paper-light) 96px
    );
  color: var(--ho-ink);
}

.section-kicker {
  margin: 0 0 8px;
  color: var(--ho-vermilion);
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-meta);
  font-weight: 690;
  letter-spacing: 0.055em;
  text-transform: uppercase;
}

.guide-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 26px;
  padding-bottom: 19px;
  border-bottom: 1px solid var(--ho-line-strong);
}

.guide-header h2,
.historical-header h2 {
  margin: 0;
  font-size: var(--ho-type-section-title);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: var(--ho-leading-title);
}

.guide-header > div > p:last-child {
  max-width: 59ch;
  margin: 10px 0 0;
  color: var(--ho-ink-muted);
  font-size: var(--ho-type-body);
  line-height: var(--ho-leading-body);
}

.local-action {
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--ho-indigo);
  border-radius: var(--ho-radius-control);
  background: transparent;
  color: var(--ho-indigo);
  cursor: pointer;
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-ui);
  font-weight: 660;
  white-space: nowrap;
}

.local-action:hover,
.local-action:focus-visible {
  background: var(--ho-indigo);
  color: var(--ho-paper-raised);
}

.why-disclosure {
  margin-top: 20px;
  border-bottom: 1px solid var(--ho-line);
}

.why-disclosure summary {
  display: grid;
  min-height: 48px;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  color: var(--ho-indigo);
  cursor: pointer;
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-ui);
  font-weight: 680;
  list-style: none;
}

.why-disclosure summary::-webkit-details-marker {
  display: none;
}

.why-disclosure summary::after {
  content: "+";
  font-size: 1.35rem;
  font-weight: 400;
  line-height: 1;
}

.why-disclosure[open] summary::after {
  content: "−";
}

.why-disclosure p {
  max-width: 66ch;
  margin: 0;
  padding: 1px 0 18px;
  color: var(--ho-ink-muted);
  font-size: var(--ho-type-body);
  line-height: var(--ho-leading-body);
}

.living-note {
  margin-top: 16px;
  padding: 12px 15px;
  border-left: 3px solid var(--ho-indigo);
  background: color-mix(in srgb, var(--ho-paper-raised) 62%, transparent);
}

.living-note strong {
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-meta);
  font-weight: 720;
}

.living-note p {
  margin: 5px 0 0;
  color: var(--ho-ink-muted);
  font-size: 0.94rem;
  line-height: 1.5;
}

.guide-layout {
  display: grid;
  grid-template-columns: minmax(190px, 218px) minmax(0, 1fr);
  gap: clamp(24px, 3vw, 38px);
  align-items: start;
  padding-top: 12px;
}

.stop-node,
.preview-detail-link,
.event-connection[href],
.person-connection[href],
.place-trail a,
.sheet-header button {
  cursor: pointer !important;
}

.route-field {
  min-width: 0;
  padding: 18px 15px 17px;
  border-top: 3px solid var(--ho-indigo);
  border-bottom: 1px solid var(--ho-line-strong);
  background:
    repeating-linear-gradient(20deg, color-mix(in srgb, var(--ho-ink) 1.6%, transparent) 0, color-mix(in srgb, var(--ho-ink) 1.6%, transparent) 1px, transparent 1px, transparent 8px),
    var(--ho-paper-light);
}

.loading-state,
.error-state {
  margin: 0;
  color: var(--ho-ink-muted);
  font-size: var(--ho-type-body);
  line-height: var(--ho-leading-body);
}

.route-group + .route-group {
  margin-top: 22px;
  padding-top: 19px;
  border-top: 1px solid var(--ho-line);
}

.route-group-header h3,
.route-group-header p {
  margin: 0;
}

.route-group-header h3 {
  font-family: var(--ho-font-ui);
  font-size: 0.94rem;
  font-weight: 690;
  line-height: 1.25;
}

.route-group-header p {
  margin-top: 3px;
  color: var(--ho-ink-muted);
  font-family: var(--ho-font-ui);
  font-size: 0.75rem;
  line-height: 1.35;
}

.stop-sequence {
  position: relative;
  display: grid;
  gap: 3px;
  margin: 13px 0 0;
  padding: 0;
  list-style: none;
}

.stop-sequence::before {
  position: absolute;
  top: 24px;
  bottom: 24px;
  left: 21px;
  width: 1px;
  background: var(--ho-line-strong);
  content: "";
}

.stop-sequence li {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.stop-node {
  display: grid;
  width: 100%;
  min-height: 62px;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 11px;
  padding: 7px 5px 7px 0;
  align-items: center;
  border: 0;
  background: transparent;
  color: var(--ho-ink);
  cursor: pointer;
  text-align: left;
}

.stop-node-visual {
  position: relative;
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--ho-line-strong);
  border-radius: 50%;
  background: var(--ho-paper-raised);
  color: var(--ho-indigo);
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.stop-node-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: sepia(0.03) saturate(0.78) contrast(0.94);
}

.stop-node-visual > span:first-child:not(.stop-node-index) {
  font-family: "Yu Mincho", "Hiragino Mincho ProN", var(--ho-font-reading);
  font-size: 0.72rem;
  font-weight: 600;
}

.stop-node-index {
  position: absolute;
  top: -1px;
  left: -1px;
  display: grid;
  width: 17px;
  height: 17px;
  place-items: center;
  border-radius: 50%;
  background: var(--ho-indigo);
  color: var(--ho-paper-raised);
  font-family: var(--ho-font-ui);
  font-size: 0.55rem;
  font-weight: 720;
  line-height: 1;
}

.stop-node-copy {
  display: block;
  min-width: 0;
}

.stop-node-copy strong,
.stop-node-copy small,
.stop-node-copy em {
  display: block;
}

.stop-node-copy strong {
  font-size: 0.88rem;
  font-weight: 580;
  line-height: 1.25;
}

.stop-node-copy small {
  margin-top: 2px;
  color: var(--ho-ink-muted);
  font-size: 0.71rem;
  line-height: 1.2;
}

.stop-node-copy em {
  margin-top: 3px;
  color: var(--ho-indigo);
  font-family: var(--ho-font-ui);
  font-size: 0.65rem;
  font-style: normal;
  font-weight: 660;
}

.stop-node:hover .stop-node-visual,
.stop-node:focus-visible .stop-node-visual {
  transform: scale(1.04);
}

.stop-node[aria-pressed="true"] {
  color: var(--ho-indigo);
}

.stop-node[aria-pressed="true"] .stop-node-visual {
  border-color: var(--ho-indigo);
  box-shadow: 0 0 0 3px var(--ho-paper-light), 0 0 0 5px var(--ho-indigo);
}

.route-footnote {
  margin: 16px 0 0;
  padding-top: 12px;
  border-top: 1px solid var(--ho-line);
  color: var(--ho-ink-muted);
  font-family: var(--ho-font-ui);
  font-size: 0.72rem;
  line-height: 1.45;
}

.stop-preview {
  position: sticky;
  top: calc(var(--ho-header-height) + 22px);
  min-height: 560px;
  padding: 0 0 24px;
  border-top: 3px solid var(--ho-indigo);
  border-bottom: 1px solid var(--ho-line-strong);
  background: var(--ho-paper-raised);
}

.stop-preview-markup {
  display: block;
  padding: 21px clamp(20px, 2.5vw, 28px) 0;
}

.preview-heading h3,
.preview-heading p {
  margin: 0;
}

.preview-heading h3 {
  font-size: var(--ho-type-list-title);
  font-weight: 530;
  letter-spacing: -0.025em;
  line-height: var(--ho-leading-title);
}

.preview-heading p {
  margin-top: 5px;
  color: var(--ho-ink-muted);
  font-size: var(--ho-type-secondary-ja);
}

.preview-cue {
  margin: 16px 0 0;
  font-size: 1.02rem;
  line-height: 1.48;
}

.preview-section {
  margin-top: 17px;
  padding-top: 13px;
  border-top: 1px solid var(--ho-line);
}

.preview-section h4,
.preview-section p {
  margin: 0;
}

.preview-section h4 {
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-meta);
  font-weight: 700;
}

.preview-section p {
  margin-top: 5px;
  color: var(--ho-ink-muted);
  font-size: 0.94rem;
  line-height: 1.54;
}

.preview-living-note {
  margin: 17px 0 0;
  padding: 11px 0 0 13px;
  border-top: 1px solid var(--ho-line);
  border-left: 3px solid var(--ho-vermilion);
  color: var(--ho-ink-muted);
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-meta);
  line-height: 1.5;
}

.preview-detail-link {
  display: flex;
  min-height: 68px;
  margin-top: 20px;
  padding: 14px 15px;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border: 1px solid var(--ho-indigo);
  border-radius: var(--ho-radius-control);
  background: var(--ho-indigo);
  color: var(--ho-paper-raised);
  text-decoration: none;
  transition: background 160ms ease, color 160ms ease;
}

.preview-detail-link:hover,
.preview-detail-link:focus-visible {
  background: transparent;
  color: var(--ho-indigo);
}

.preview-detail-link strong,
.preview-detail-link small {
  display: block;
}

.preview-detail-link strong {
  font-size: 0.98rem;
  font-weight: 650;
}

.preview-detail-link small {
  margin-top: 3px;
  color: currentColor;
  font-family: var(--ho-font-ui);
  font-size: 0.76rem;
  line-height: 1.35;
  opacity: 0.84;
}

.historical-header {
  padding-bottom: 18px;
  border-bottom: 1px solid var(--ho-line-strong);
}

.connection-section,
.historical-layers {
  margin-top: 29px;
}

.connection-section + .connection-section,
.historical-layers {
  padding-top: 25px;
  border-top: 1px solid var(--ho-line-strong);
}

.connection-section h3,
.historical-layers h3 {
  margin: 0 0 10px;
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-meta);
  font-weight: 720;
}

.event-connection,
.person-connection {
  display: grid;
  width: 100%;
  padding: 14px 0;
  border-bottom: 1px solid var(--ho-line);
  color: var(--ho-ink);
  text-decoration: none;
}

a.person-connection {
  cursor: pointer;
}

a.person-connection:hover strong,
a.person-connection:focus-visible strong {
  color: var(--ho-indigo);
}

.event-connection {
  grid-template-columns: 48px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  font-family: var(--ho-font-reading);
}

button.event-connection {
  border: 0;
  border-bottom: 1px solid var(--ho-line);
  background: transparent;
  font: inherit;
  text-align: left;
}

.event-connection > span:first-child {
  padding-top: 2px;
  color: var(--ho-vermilion);
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-meta);
  font-weight: 700;
}

.event-connection-copy strong,
.event-connection-copy small {
  display: block;
}

.event-connection-copy strong {
  font-size: 0.98rem;
  font-weight: 550;
  line-height: 1.35;
}

.event-connection-copy small {
  margin-top: 6px;
  color: var(--ho-ink-muted);
  font-family: var(--ho-font-reading);
  font-size: 0.84rem;
  line-height: 1.45;
}

.person-connection {
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.person-connection img { width: 46px; height: 46px; border: 1px solid var(--ho-line-strong); border-radius: 50%; object-fit: cover; }
.person-connection > span { display: grid; gap: 2px; }

.person-connection strong {
  font-size: 1rem;
  font-weight: 550;
}

.person-connection small {
  color: var(--ho-ink-muted);
  font-size: var(--ho-type-secondary-ja);
}

a.event-connection:hover strong,
a.event-connection:focus-visible strong,
button.event-connection:hover strong,
button.event-connection:focus-visible strong {
  color: var(--ho-indigo);
}

.connection-arrow {
  padding-top: 2px;
  color: var(--ho-indigo);
  transition: transform 160ms ease;
}

a.event-connection:hover .connection-arrow,
a.event-connection:focus-visible .connection-arrow,
button.event-connection:hover .connection-arrow,
button.event-connection:focus-visible .connection-arrow {
  transform: translateX(4px);
}

.place-layers {
  margin: 0;
  border-top: 1px solid var(--ho-line-strong);
}

.place-layers div {
  padding: 14px 0;
  border-bottom: 1px solid var(--ho-line);
}

.place-layers dt {
  color: var(--ho-vermilion);
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-meta);
  font-weight: 680;
}

.place-layers dd {
  margin: 5px 0 0;
  color: var(--ho-ink-muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

.global-entry-links {
  margin-top: clamp(52px, 7vw, 84px);
}

dialog {
  max-height: calc(100dvh - 36px);
  padding: 0;
  overflow: auto;
  border: 1px solid var(--ho-line-strong);
  border-radius: 0;
  background: var(--ho-paper-raised);
  color: var(--ho-ink);
  box-shadow: 0 22px 70px color-mix(in srgb, var(--ho-ink) 28%, transparent);
}

dialog::backdrop {
  background: rgba(20, 39, 44, 0.45);
}

.stop-sheet {
  width: min(620px, calc(100% - 32px));
}

.all-stops-dialog {
  width: min(830px, calc(100% - 32px));
}

.sheet-header {
  position: sticky;
  z-index: 2;
  top: 0;
  display: flex;
  min-height: 68px;
  padding: 16px 20px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--ho-line-strong);
  background: color-mix(in srgb, var(--ho-paper-raised) 95%, transparent);
  backdrop-filter: blur(10px);
}

.sheet-header h2,
.sheet-header p {
  margin: 0;
}

.sheet-header h2 {
  font-size: 1.45rem;
  font-weight: 530;
}

.sheet-header p {
  margin-bottom: 3px;
  color: var(--ho-vermilion);
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-meta);
  font-weight: 690;
}

.sheet-header button {
  padding: 8px 0;
  border: 0;
  background: transparent;
  color: var(--ho-indigo);
  cursor: pointer;
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-ui);
  font-weight: 670;
}

.sheet-body {
  padding: 22px 22px 30px;
}

.sheet-body .stop-preview-markup {
  padding: 0;
}

.all-stops-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 28px;
  padding: 12px 24px 30px;
}

.all-stop-button {
  display: grid;
  width: 100%;
  min-height: 120px;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  gap: 13px;
  padding: 18px 0;
  align-items: start;
  border: 0;
  border-bottom: 1px solid var(--ho-line);
  background: transparent;
  color: var(--ho-ink);
  cursor: pointer;
  text-align: left;
}

.all-stop-index {
  color: var(--ho-vermilion);
  font-family: var(--ho-font-ui);
  font-size: var(--ho-type-meta);
  font-weight: 720;
}

.all-stop-copy strong,
.all-stop-copy span,
.all-stop-copy small {
  display: block;
}

.all-stop-copy strong {
  font-size: 1.08rem;
  font-weight: 540;
}

.all-stop-copy span {
  margin-top: 3px;
  color: var(--ho-ink-muted);
  font-size: var(--ho-type-secondary-ja);
}

.all-stop-copy small {
  margin-top: 8px;
  color: var(--ho-ink-muted);
  font-family: var(--ho-font-reading);
  font-size: 0.86rem;
  line-height: 1.42;
}

.all-stop-button > span:last-child {
  align-self: center;
  color: var(--ho-indigo);
  transition: transform 160ms ease;
}

.all-stop-button:hover > span:last-child,
.all-stop-button:focus-visible > span:last-child {
  transform: translateX(4px);
}

@media (max-width: 1060px) {
  .place-reading-grid {
    grid-template-columns: minmax(0, 1.55fr) minmax(300px, 0.85fr);
  }

  .guide-layout {
    grid-template-columns: 190px minmax(0, 1fr);
    gap: 24px;
  }

  .today-guide {
    padding-right: 32px;
  }

  .historical-context {
    padding-right: 28px;
    padding-left: 28px;
  }
}

@media (max-width: 880px) {
  .place-reading-grid {
    grid-template-columns: 1fr;
  }

  .historical-context {
    padding-top: 106px;
    background:
      repeating-linear-gradient(20deg, color-mix(in srgb, var(--ho-ink) 1.65%, transparent) 0, color-mix(in srgb, var(--ho-ink) 1.65%, transparent) 1px, transparent 1px, transparent 8px),
      linear-gradient(
        180deg,
        var(--ho-coastal-page) 0,
        color-mix(in srgb, var(--ho-coastal-page) 54%, var(--ho-historical-paper-light)) 48px,
        var(--ho-historical-paper-light) 98px
      );
  }

  .today-guide,
  .historical-context {
    padding-right: var(--ho-gutter);
    padding-left: var(--ho-gutter);
  }

  .historical-context {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 36px;
  }

  .historical-header {
    grid-column: 1 / -1;
  }

  .historical-layers {
    grid-column: 1 / -1;
  }
}

@media (max-width: 720px) {
  .place-banner {
    min-height: 228px;
  }

  .place-banner figure::after {
    background:
      linear-gradient(90deg, var(--ho-paper-light) 0%, color-mix(in srgb, var(--ho-paper-light) 95%, transparent) 64%, color-mix(in srgb, var(--ho-paper-light) 36%, transparent) 100%),
      linear-gradient(0deg, rgba(24, 49, 57, 0.2), transparent 44%);
  }

  .place-banner-copy {
    width: calc(100% - (var(--ho-gutter) * 2));
    padding: 24px 0 28px;
  }

  .place-banner h1 {
    margin-top: 48px;
  }

  .place-banner figcaption {
    right: 10px;
    bottom: 8px;
    max-width: 48%;
    text-align: right;
  }

  .today-guide,
  .historical-context {
    padding-top: 34px;
    padding-bottom: 50px;
  }

  .historical-context {
    padding-top: 96px;
  }

  .guide-header {
    display: block;
  }

  .local-action {
    width: 100%;
    margin-top: 17px;
  }

  .guide-layout {
    display: block;
    padding-top: 22px;
  }

  .route-field {
    padding: 18px 14px;
  }

  .stop-preview {
    display: none;
  }

  .historical-context {
    display: block;
  }

  .connection-section,
  .historical-layers {
    margin-top: 25px;
  }

  .connection-section + .connection-section,
  .historical-layers {
    padding-top: 22px;
  }

  .stop-sheet {
    width: 100%;
    max-width: none;
    max-height: 88dvh;
    margin: auto 0 0;
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
  }

  .all-stops-dialog {
    width: calc(100% - 20px);
    max-height: calc(100dvh - 20px);
  }

  .all-stops-grid {
    grid-template-columns: 1fr;
    padding: 10px 18px 26px;
  }

  .all-stop-button {
    min-height: 110px;
  }
}
