.hero .contribution {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}

.demo-guide strong {
  display: inline-block;
  min-width: 22px;
  color: var(--orange);
  font-size: 10px;
  letter-spacing: .04em;
}

.nav {
  transition: transform .4s cubic-bezier(.22, 1, .36, 1);
}

.nav.is-hidden {
  transform: translateY(calc(-100% - 4px));
}

.nav-reveal {
  position: fixed;
  z-index: 21;
  inset: 0 0 auto;
  width: 100%;
  height: 14px;
  padding: 0;
  border: 0;
  background: transparent;
  opacity: 0;
  pointer-events: none;
}

.nav-reveal::after {
  display: none !important;
}

.nav-reveal.is-active {
  pointer-events: auto;
}

.place-thumb {
  overflow: hidden;
  background-image: url("assets/amap/palace-poi-sprite.webp") !important;
  background-size: 400% 200% !important;
  background-repeat: no-repeat !important;
  color: transparent !important;
}

.place-thumb.rest-a { background-position: 0 0 !important; }
.place-thumb.rest-b { background-position: 66.666% 100% !important; }
.place-thumb.rest-c { background-position: 100% 100% !important; }
.place-thumb.photo-a { background-position: 33.333% 0 !important; }
.place-thumb.photo-b { background-position: 66.666% 0 !important; }
.place-thumb.photo-c { background-position: 100% 0 !important; }

.place-list article[role="button"] {
  position: relative;
  cursor: pointer;
  outline: 0;
  transition: transform .25s cubic-bezier(.22, 1, .36, 1),
    box-shadow .25s ease,
    border-color .25s ease;
  border: 1px solid transparent;
}

.place-list article[role="button"]:hover,
.place-list article[role="button"]:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(241, 83, 37, .28);
  box-shadow: 0 8px 20px rgba(35, 54, 57, .13);
}

.place-list article[role="button"].is-selected {
  border-color: rgba(241, 83, 37, .58);
  box-shadow: 0 0 0 2px rgba(241, 83, 37, .11),
    0 8px 20px rgba(35, 54, 57, .12);
}

.place-action {
  border-radius: 7px;
  background: #edf5ff;
  color: #2877d5;
  padding: 8px 10px;
  font-size: 10px;
  font-weight: 650;
}

.demo-poi {
  transform-origin: 22px 38px;
  transition: transform .28s cubic-bezier(.22, 1, .36, 1),
    filter .28s ease,
    opacity .28s ease;
}

.demo-poi.is-muted {
  opacity: .55;
  filter: saturate(.65) drop-shadow(0 2px 2px rgba(54, 70, 71, .12));
}

.demo-poi.is-selected {
  z-index: 4;
  transform: scale(1.25);
  filter: drop-shadow(0 5px 8px rgba(241, 83, 37, .28));
}

.demo-poi.is-selected .poi-thumb {
  border-color: #f15325;
  box-shadow: 0 0 0 3px rgba(241, 83, 37, .2);
  animation: selectedPoiPulse .72s cubic-bezier(.22, 1, .36, 1) 1;
}

@keyframes selectedPoiPulse {
  0% { box-shadow: 0 0 0 0 rgba(241, 83, 37, .5); }
  65% { box-shadow: 0 0 0 10px rgba(241, 83, 37, 0); }
  100% { box-shadow: 0 0 0 3px rgba(241, 83, 37, .2); }
}

@media (max-width: 700px) {
  .hero .contribution {
    margin-bottom: 16px;
  }
}

/* Direct mobile entry is a compact product workbench. Copy and the complete
   interactive screen share the first viewport instead of stacking into a
   two-thousand-pixel hero. The transition-specific shared shell keeps its
   separate geometry rules above. */
@media (max-width: 700px) {
  html:not(.from-amap-cover) .hero.section {
    height: calc(100svh - 64px);
    min-height: 566px;
    padding: 14px 20px 10px;
    display: grid;
    grid-template: auto minmax(0, 1fr) / minmax(0, 1fr);
    gap: 8px;
    align-items: start;
    overflow: hidden;
  }

  html:not(.from-amap-cover) .hero .copy {
    max-width: none;
    min-width: 0;
  }

  html:not(.from-amap-cover) .hero .kick {
    margin: 0;
    font-size: 9px;
  }

  html:not(.from-amap-cover) .hero .copy h1 {
    margin: 5px 0 6px;
    font-size: clamp(28px, 7.8vw, 34px);
    line-height: 1.08;
  }

  html:not(.from-amap-cover) .hero .copy h1 br {
    display: none;
  }

  html:not(.from-amap-cover) .hero .lead {
    display: -webkit-box;
    max-width: 350px;
    margin: 0;
    overflow: hidden;
    color: #5b554d;
    font-size: 11px;
    line-height: 1.42;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  html:not(.from-amap-cover) .hero .copy dl,
  html:not(.from-amap-cover) .hero .contribution,
  html:not(.from-amap-cover) .hero .note {
    display: none;
  }

  html:not(.from-amap-cover) .hero .primary {
    min-width: 128px;
    min-height: 42px;
    margin-top: 7px;
    padding: 9px 18px;
  }

  html:not(.from-amap-cover) .hero .online-demo {
    width: 100%;
    height: 100%;
    min-height: 0;
    align-items: center;
    justify-content: center;
    gap: 0;
    overflow: hidden;
  }

  html:not(.from-amap-cover) .hero .online-demo .demo-guide {
    display: none;
  }
}

@media (max-width: 700px) and (max-height: 700px) {
  html:not(.from-amap-cover) .hero.section {
    min-height: 0;
    padding: 10px 12px 8px;
    grid-template: minmax(0, 1fr) / minmax(128px, 138px) minmax(0, 1fr);
    gap: 10px;
    align-items: center;
  }

  html:not(.from-amap-cover) .hero .copy h1 {
    margin: 7px 0 10px;
    font-size: clamp(25px, 7.2vw, 29px);
    line-height: 1.08;
  }

  html:not(.from-amap-cover) .hero .lead {
    display: none;
  }

  html:not(.from-amap-cover) .hero .primary {
    width: 100%;
    min-width: 0;
    min-height: 44px;
    margin-top: 0;
    padding-inline: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .demo-poi.is-selected .poi-thumb {
    animation: none;
  }
}
html.from-amap-cover {
  scroll-behavior: auto;
}

html.from-amap-cover:not(.amap-entry-complete) body {
  overflow: hidden;
}

html.from-amap-cover .hero.section {
  position: relative;
  display: block;
  min-height: calc(100svh - 82px);
  padding: 0;
  overflow: hidden;
}

html.from-amap-cover .hero .copy {
  position: absolute;
  z-index: 4;
  left: clamp(44px, 5vw, 76px);
  top: clamp(48px, 8vh, 82px);
  width: min(34vw, 510px);
}

html.from-amap-cover .hero .demo {
  position: absolute;
  inset: 0;
  display: block;
  min-height: 0;
  pointer-events: none;
}

html.from-amap-cover .hero .demo::before {
  left: calc(var(--amap-entry-phone-left) + var(--amap-entry-phone-width) / 2 - 280px);
  top: calc(var(--amap-entry-phone-top) + var(--amap-entry-phone-height) / 2 - 280px);
}

html.from-amap-cover .hero .palace-phone {
  position: fixed;
  z-index: 50;
  left: var(--amap-entry-phone-left);
  top: var(--amap-entry-phone-top);
  width: var(--amap-entry-phone-width) !important;
  height: var(--amap-entry-phone-height);
  margin: 0;
  visibility: hidden !important;
  pointer-events: none;
  transform: none;
}

html.from-amap-cover.amap-entry-anchored .hero .palace-phone {
  position: absolute;
}

html.from-amap-cover .hero .demo-guide {
  display: none;
}

.hero .hero-entry {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 14px;
  max-width: 510px;
  margin: 16px 0 10px;
  padding: 11px 13px;
}

.hero .hero-entry .live-entry-title {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0;
}

.hero .hero-entry .entry-path {
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 8px;
  min-width: 0;
  padding: 7px 0 1px;
}

.hero .hero-entry .entry-path-icon {
  width: 34px;
  height: 34px;
}

.hero .hero-entry .entry-path strong {
  color: #23312f;
  font-size: 10px;
  font-weight: 700;
}

.hero .hero-entry .entry-path small {
  font-size: 8px;
  line-height: 1.42;
}

.amap-entry-sheet {
  position: fixed;
  z-index: 40;
  inset: -3%;
  pointer-events: none;
  background-color: #f3efe7;
  background-image:
    linear-gradient(rgba(63, 57, 47, .038) 1px, transparent 1px),
    linear-gradient(90deg, rgba(63, 57, 47, .038) 1px, transparent 1px),
    radial-gradient(circle at 78% 18%, rgba(241, 83, 37, .055), transparent 26%);
  background-size: 42px 42px, 42px 42px, auto;
  box-shadow: -34px 0 70px rgba(56, 43, 31, .17);
  will-change: clip-path, transform;
}

.amap-entry-bridge {
  position: fixed;
  z-index: 60;
  pointer-events: none;
  transform-origin: 52% 58%;
  will-change: transform;
  -webkit-mask-image: linear-gradient(to bottom, #000 0 82%, rgba(0, 0, 0, .82) 87%, transparent 95%);
  mask-image: linear-gradient(to bottom, #000 0 82%, rgba(0, 0, 0, .82) 87%, transparent 95%);
}

.amap-entry-bridge.is-anchored {
  position: absolute;
}

html.amap-entry-complete .amap-entry-bridge {
  z-index: 10;
  will-change: auto;
}

.amap-entry-composite {
  position: absolute;
  inset: 0;
}

.amap-entry-bridge img {
  position: absolute;
  z-index: 2;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}

.amap-entry-live-screen {
  position: absolute;
  z-index: 1;
  left: 39.65%;
  top: 6.75%;
  width: 21.9%;
  height: 71.4%;
  overflow: hidden;
  border: 0;
  border-radius: 9.2% / 4.7%;
  background: #e8efeb;
  pointer-events: auto;
}

html.from-amap-cover .hero.section {
  min-height: var(--amap-entry-mobile-min-height);
}

@media (max-width: 700px) {
  html.from-amap-cover .hero .copy {
    left: 20px;
    top: 20px;
    width: calc(100vw - 40px);
  }

  html.from-amap-cover .hero .copy h1 {
    margin: 12px 0;
    font-size: 38px;
    line-height: 1.12;
  }

  html.from-amap-cover .hero .lead {
    font-size: 13px;
    line-height: 1.62;
  }

  html.from-amap-cover .hero .copy dl,
  html.from-amap-cover .hero .contribution,
  html.from-amap-cover .hero .note {
    display: none;
  }

  .hero .hero-entry {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px 8px;
    width: 100%;
    margin: 7px 0 0;
    padding: 7px 9px;
  }

  .hero .hero-entry .live-entry-title {
    justify-content: space-between;
    gap: 6px;
  }

  .hero .hero-entry .live-entry-title em {
    padding: 2px 5px;
    font-size: 7px;
  }

  .hero .hero-entry .live-entry-title b {
    font-size: 10px;
  }

  .hero .hero-entry .entry-path {
    display: block;
    padding: 5px 0 1px;
  }

  .hero .hero-entry .entry-path-icon,
  .hero .hero-entry .entry-path small {
    display: none;
  }

  .hero .hero-entry .entry-path strong {
    font-size: 9px;
  }

}

@media (prefers-reduced-motion: reduce) {
  .amap-entry-sheet,
  .amap-entry-bridge {
    display: none;
  }
}

/* Unified case hero: the transition lands on the same interactive handheld
   device that remains on the page. The live screen sits above the baked frame
   highlight and is clipped to one continuous aperture. */
.hero.section {
  position: relative;
  display: block;
  height: calc(100svh - 82px);
  min-height: 780px;
  padding: 0;
  overflow: hidden;
}

.hero .copy,
html.from-amap-cover .hero .copy {
  position: absolute;
  z-index: 5;
  left: clamp(44px, 5vw, 76px);
  top: clamp(42px, 6.5vh, 72px);
  width: min(36vw, 590px);
  max-width: none;
}

.hero .copy h1 {
  margin: 18px 0;
  font-size: clamp(54px, 4.7vw, 82px);
  line-height: 1.12;
}

.hero .lead {
  font-size: clamp(14px, 1.05vw, 17px);
  line-height: 1.75;
}

.hero .copy dl {
  margin: 20px 0 14px;
  padding-top: 14px;
}

.hero .contribution,
.hero .note {
  margin-block: 9px;
}

.hero .demo,
html.from-amap-cover .hero .demo {
  position: absolute;
  inset: 0;
  display: block;
  min-height: 0;
  pointer-events: none;
}

.hero .demo::before {
  left: 58%;
  top: 18%;
}

.hero .palace-phone {
  display: none !important;
}

.amap-case-device {
  position: absolute;
  z-index: 3;
  left: 35%;
  bottom: -40px;
  width: min(1500px, 96vw);
  aspect-ratio: 1624 / 968;
  transform-origin: 0 0;
  pointer-events: none;
  will-change: transform;
  -webkit-mask-image: linear-gradient(to bottom, #000 0 91%, rgba(0, 0, 0, .82) 95%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 0 91%, rgba(0, 0, 0, .82) 95%, transparent 100%);
}

.amap-case-device > img {
  position: absolute;
  z-index: 2;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}

.amap-case-live-screen {
  position: absolute;
  z-index: 3;
  left: 39.37%;
  top: 7.55%;
  width: 21.1%;
  height: 71%;
  display: block;
  overflow: hidden;
  border: 0;
  border-radius: 12.7% / 6.2%;
  clip-path: inset(0 round 12.7% 12.7% 12.7% 12.7% / 6.2% 6.2% 6.2% 6.2%);
  background: transparent;
  pointer-events: auto;
  contain: size layout paint style;
  isolation: isolate;
}

html:not(.amap-entry-animating) .amap-case-device {
  will-change: auto;
}

.hero .copy .demo-guide,
html.from-amap-cover .hero .copy .demo-guide {
  position: static;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  gap: 8px 10px;
  width: 100%;
  max-width: 590px;
  margin-top: 12px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 10px;
}

.hero .copy .demo-guide b {
  grid-column: 1 / -1;
  color: var(--ink);
  font: 500 17px Georgia, "Songti SC", serif;
}

.hero .copy .demo-guide span {
  white-space: nowrap;
}

.hero .copy .demo-guide .secondary {
  grid-column: 4;
  grid-row: 2;
  padding: 7px 10px;
  white-space: nowrap;
  font-size: 10px;
}

@media (max-width: 1100px) {
  .hero .copy,
  html.from-amap-cover .hero .copy {
    width: min(42vw, 500px);
  }

  .amap-case-device {
    left: 30%;
    width: min(1300px, 112vw);
  }

  .hero .hero-entry .entry-path small,
  .hero .note {
    display: none;
  }
}

@media (max-width: 700px) {
  .hero.section,
  html:not(.from-amap-cover) .hero.section,
  html.from-amap-cover .hero.section {
    height: 920px;
    min-height: 920px;
    padding: 0;
  }

  .hero .copy,
  html:not(.from-amap-cover) .hero .copy,
  html.from-amap-cover .hero .copy {
    left: 20px;
    top: 18px;
    width: calc(100vw - 40px);
    max-width: none;
  }

  .hero .kick {
    display: block !important;
    margin: 0;
    font-size: 10px;
  }

  .hero .copy h1,
  html.from-amap-cover .hero .copy h1 {
    margin: 10px 0;
    font-size: 38px;
    line-height: 1.12;
  }

  .hero .lead,
  html.from-amap-cover .hero .lead {
    font-size: 12px;
    line-height: 1.58;
  }

  .hero .copy dl,
  .hero .contribution,
  .hero .hero-entry,
  .hero .note,
  .hero .copy .demo-guide {
    display: none !important;
  }

  .amap-case-device {
    left: -90%;
    bottom: 70px;
    width: 235vw;
  }
}

@media (prefers-reduced-motion: reduce) {
  .amap-case-device {
    will-change: auto;
  }
}
