/* Memory Echo v3: one calm, meaningful resurfaced memory at a time. */
html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-feature,
html body main.app-shell section.map-stage.home-focus #homeOnThisDay .memory-echo-feature {
  width: 100% !important;
  max-width: min(100%, 900px) !important;
  margin-inline: auto !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-feature-card.is-simplified,
html body main.app-shell section.map-stage.home-focus #homeOnThisDay .memory-echo-feature-card.is-simplified {
  position: relative !important;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto !important;
  grid-template-areas:
    "reason reason"
    "body action"
    "navigation navigation" !important;
  align-items: center !important;
  width: 100% !important;
  min-height: 176px !important;
  padding: clamp(16px, 2.5vw, 22px) !important;
  gap: 12px 18px !important;
  overflow: hidden !important;
  border: 1px solid color-mix(in srgb, var(--echo-accent, #1a9f80) 20%, rgba(16, 83, 91, 0.1)) !important;
  border-radius: 18px !important;
  background:
    linear-gradient(118deg, rgba(255, 254, 250, 0.97), rgba(243, 251, 248, 0.95) 66%, color-mix(in srgb, var(--echo-accent, #1a9f80) 8%, #eef8f5)) !important;
  box-shadow:
    0 18px 38px rgba(10, 64, 69, 0.095),
    inset 0 1px 0 rgba(255, 255, 255, 0.96) !important;
  transform: translateZ(0) !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-feature-card.is-simplified::before {
  position: absolute !important;
  top: 0 !important;
  bottom: 0 !important;
  left: 0 !important;
  width: 3px !important;
  content: "" !important;
  background: var(--echo-accent, #1a9f80) !important;
  opacity: 0.74 !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-feature-card.is-simplified::after {
  position: absolute !important;
  right: -44px !important;
  bottom: -72px !important;
  width: 180px !important;
  height: 180px !important;
  content: "" !important;
  border-radius: 50% !important;
  background: color-mix(in srgb, var(--echo-accent, #1a9f80) 8%, transparent) !important;
  filter: blur(18px) !important;
  pointer-events: none !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-reason-stack {
  grid-area: reason !important;
  z-index: 2 !important;
  display: flex !important;
  justify-content: flex-start !important;
  min-width: 0 !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-reason {
  display: inline-flex !important;
  align-items: center !important;
  min-height: 28px !important;
  padding: 6px 10px !important;
  border: 1px solid color-mix(in srgb, var(--echo-accent, #1a9f80) 16%, rgba(21, 83, 91, 0.08)) !important;
  border-radius: 999px !important;
  color: #315f67 !important;
  background: rgba(255, 255, 252, 0.66) !important;
  font-size: 0.68rem !important;
  font-style: normal !important;
  font-weight: 720 !important;
  line-height: 1 !important;
  letter-spacing: 0 !important;
  text-transform: none !important;
  white-space: normal !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-body,
html body main.app-shell section.map-stage.home-focus #homeOnThisDay .memory-echo-body {
  grid-area: body !important;
  z-index: 2 !important;
  display: grid !important;
  grid-template-columns: clamp(96px, 11vw, 116px) minmax(0, 1fr) !important;
  align-items: center !important;
  min-width: 0 !important;
  gap: clamp(14px, 2vw, 20px) !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-thumb,
html body main.app-shell section.map-stage.home-focus #homeOnThisDay .memory-echo-thumb {
  position: relative !important;
  display: block !important;
  width: clamp(96px, 11vw, 116px) !important;
  height: clamp(96px, 11vw, 116px) !important;
  min-width: 0 !important;
  min-height: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
  border: 1px solid rgba(255, 255, 255, 0.84) !important;
  border-radius: 13px !important;
  background: #e7f3ef !important;
  box-shadow: 0 10px 22px rgba(8, 60, 66, 0.12) !important;
  transform: translateZ(0) !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-thumb.has-photo > img,
html body main.app-shell section.map-stage.home-focus #homeOnThisDay .memory-echo-thumb.has-photo > img {
  position: absolute !important;
  inset: 0 !important;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: var(--home-photo-position, center 32%) !important;
  opacity: 1 !important;
  filter: none !important;
  transform: scale(1.015) !important;
  transition: transform 900ms cubic-bezier(0.2, 0.72, 0.2, 1) !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-copy-main,
html body main.app-shell section.map-stage.home-focus #homeOnThisDay .memory-echo-copy-main {
  display: grid !important;
  min-width: 0 !important;
  padding: 0 !important;
  gap: 7px !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-copy-main strong {
  overflow: hidden !important;
  color: #0d3f4a !important;
  font-size: clamp(1.05rem, 2.2vw, 1.38rem) !important;
  font-weight: 820 !important;
  line-height: 1.12 !important;
  letter-spacing: 0 !important;
  text-overflow: ellipsis !important;
  text-wrap: balance !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-copy-main small {
  display: -webkit-box !important;
  max-width: 44ch !important;
  overflow: hidden !important;
  color: #527078 !important;
  font-size: clamp(0.72rem, 1.2vw, 0.82rem) !important;
  font-weight: 610 !important;
  line-height: 1.38 !important;
  -webkit-box-orient: vertical !important;
  -webkit-line-clamp: 2 !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-why-now,
html body main.app-shell section.map-stage.home-focus #homeOnThisDay .memory-echo-why-now {
  display: block !important;
  color: color-mix(in srgb, var(--echo-accent, #1a9f80) 76%, #174b56) !important;
  font-size: clamp(0.7rem, 1.15vw, 0.78rem) !important;
  font-weight: 760 !important;
  line-height: 1.3 !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-story,
html body main.app-shell section.map-stage.home-focus #homeOnThisDay .memory-echo-story {
  display: -webkit-box !important;
  max-width: 48ch !important;
  overflow: hidden !important;
  color: #365f68 !important;
  font-size: clamp(0.74rem, 1.2vw, 0.84rem) !important;
  font-style: italic !important;
  font-weight: 560 !important;
  line-height: 1.38 !important;
  -webkit-box-orient: vertical !important;
  -webkit-line-clamp: 2 !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-relive {
  grid-area: action !important;
  z-index: 3 !important;
  align-self: center !important;
  min-width: 158px !important;
  min-height: 42px !important;
  padding: 10px 15px !important;
  border: 1px solid color-mix(in srgb, var(--echo-accent, #1a9f80) 26%, rgba(255, 255, 255, 0.35)) !important;
  border-radius: 999px !important;
  color: #ffffff !important;
  background: linear-gradient(135deg, #0b5361, color-mix(in srgb, var(--echo-accent, #1a9f80) 76%, #0b6f75)) !important;
  box-shadow: 0 10px 22px color-mix(in srgb, var(--echo-accent, #1a9f80) 20%, transparent) !important;
  font-size: 0.76rem !important;
  font-weight: 820 !important;
  letter-spacing: 0 !important;
  transition: transform 180ms ease, box-shadow 180ms ease !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-relive:hover,
html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-relive:focus-visible {
  box-shadow: 0 13px 26px color-mix(in srgb, var(--echo-accent, #1a9f80) 28%, transparent) !important;
  transform: translateY(-1px) !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-navigation {
  grid-area: navigation !important;
  z-index: 3 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 26px !important;
  gap: 9px !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-nav-button {
  display: grid !important;
  width: 26px !important;
  height: 26px !important;
  place-items: center !important;
  padding: 0 !important;
  border: 1px solid rgba(19, 91, 99, 0.1) !important;
  border-radius: 50% !important;
  color: #285d66 !important;
  background: rgba(255, 255, 252, 0.66) !important;
  box-shadow: none !important;
  font-size: 1rem !important;
  line-height: 1 !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-dots {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-dot {
  width: 6px !important;
  height: 6px !important;
  min-width: 6px !important;
  min-height: 6px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 50% !important;
  background: rgba(36, 95, 103, 0.2) !important;
  box-shadow: none !important;
  transition: width 180ms ease, background-color 180ms ease !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-dot.active {
  width: 18px !important;
  border-radius: 999px !important;
  background: var(--echo-accent, #1a9f80) !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay.is-switching-echo .memory-echo-feature-card {
  opacity: 0 !important;
  transform: translateY(8px) scale(0.992) !important;
}

html body .app-shell .map-stage.home-focus #homeOnThisDay.is-arriving-echo .memory-echo-feature-card {
  animation: memory-echo-arrive-v2 620ms cubic-bezier(0.22, 0.72, 0.24, 1) both !important;
}

@media (hover: hover) and (pointer: fine) {
  html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-thumb:hover > img {
    transform: scale(1.055) !important;
  }
}

@keyframes memory-echo-arrive-v2 {
  from { opacity: 0; transform: translateY(8px) scale(0.992); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 720px) {
  html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-feature-card.is-simplified,
  html body main.app-shell section.map-stage.home-focus #homeOnThisDay .memory-echo-feature-card.is-simplified {
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "reason"
      "body"
      "action"
      "navigation" !important;
    min-height: 0 !important;
    padding: 14px !important;
    gap: 11px !important;
    border-radius: 16px !important;
  }

  html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-reason-stack {
    justify-content: center !important;
  }

  html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-body,
  html body main.app-shell section.map-stage.home-focus #homeOnThisDay .memory-echo-body {
    grid-template-columns: 105px minmax(0, 1fr) !important;
    gap: 14px !important;
  }

  html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-thumb,
  html body main.app-shell section.map-stage.home-focus #homeOnThisDay .memory-echo-thumb {
    width: 105px !important;
    height: 105px !important;
    min-width: 105px !important;
    min-height: 105px !important;
    border-radius: 14px !important;
  }

  html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-copy-main strong {
    font-size: clamp(0.98rem, 4.4vw, 1.16rem) !important;
  }

  html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-copy-main small {
    font-size: 0.7rem !important;
  }

  html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-relive {
    justify-self: center !important;
    width: min(100%, 206px) !important;
    min-height: 40px !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  html body .app-shell .map-stage.home-focus #homeOnThisDay.is-arriving-echo .memory-echo-feature-card {
    animation: none !important;
  }

  html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-feature-card,
  html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-thumb > img,
  html body .app-shell .map-stage.home-focus #homeOnThisDay .memory-echo-relive {
    transition: none !important;
  }
}
