/* Memory Lane: one browsing hierarchy, shared MyMappi navy/mint language.
   The id scopes this final layer; capsule, editor and map styling are untouched. */
html body #memoryLanePage .memory-backup-detail { margin-top: 8px; }
html body #memoryLanePage .memory-backup-detail summary { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-height: 44px; cursor: pointer; white-space: normal; }
html body #memoryLanePage .memory-backup-hint { font-size: .75rem; text-decoration: underline; text-underline-offset: 3px; }
html body #memoryLanePage .memory-backup-detail p { font-size: .8125rem; line-height: 1.5; color: #506b7b; margin: 6px 0 0; overflow-wrap: anywhere; }
html body #memoryLanePage .memory-backup-detail summary:focus-visible { outline: 3px solid #287e9a; outline-offset: 3px; border-radius: 8px; }
html body #memoryLanePage .memory-lane-more {
  display: flex;
  justify-content: center;
  padding: 18px 0 24px;
}
html body #memoryLanePage .memory-lane-more button {
  min-height: 48px;
  padding: 12px 20px;
  border: 1px solid #bfd9da;
  border-radius: 14px;
  background: #e6f5f1;
  color: #00243f;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
html body #memoryLanePage .memory-lane-more button:focus-visible {
  outline: 3px solid #00243f;
  outline-offset: 3px;
}
html body main.app-shell section.map-stage.memories-focus #memoryLanePage {
  --memory-lane-ink: var(--mymappi-text-primary);
  --memory-lane-muted: var(--mymappi-text-muted);
  --memory-lane-teal: var(--mymappi-action-navy);
  --memory-lane-deep: var(--mymappi-action-navy);
  --memory-lane-green: var(--mymappi-color-mint);
  --memory-lane-line: #c5d8e2;
  --memory-card-v3-ink: #00243f;
  --memory-card-v3-muted: #526d7b;
  --memory-card-v3-ivory: #fbfefd;
  --lane-width: 1180px;
  color: var(--mymappi-text-primary) !important;
  background: #edf5fa !important;
}

/* Empty accounts, Timeline, Stories and Insights must share the same brand
   as the populated cards. These used independent legacy teal declarations. */
html body main.app-shell section.map-stage.memories-focus #memoryLanePage :is(.memory-lane-empty-art, .memory-lane-view-icon) {
  color: #fff !important;
  background: var(--mymappi-action-navy) !important;
}
html body main.app-shell section.map-stage.memories-focus #memoryLanePage :is(.memory-lane-empty-copy > span, .memory-lane-group-heading small, .memory-lane-insight-feature small, .world-passport-heading small) {
  color: var(--mymappi-text-muted) !important;
}
html body main.app-shell section.map-stage.memories-focus #memoryLanePage .memory-lane-view-intro > small {
  color: var(--mymappi-text-primary) !important;
  background: #e4f5f1 !important;
}
html body main.app-shell section.map-stage.memories-focus #memoryLanePage .world-passport-country-card {
  color: var(--mymappi-text-primary) !important;
  background: #fff !important;
  border-color: #c5d8e2 !important;
}
html body main.app-shell section.map-stage.memories-focus #memoryLanePage :is(.world-passport-country-flag, .world-passport-country-action) {
  color: var(--mymappi-text-primary) !important;
  background: #e4f5f1 !important;
}
html body #memoryLanePage .memory-lane-search > svg { color: var(--mymappi-text-muted) !important; }
html body main.app-shell section.map-stage.memories-focus #memoryLanePage :is(.memory-lane-empty-copy strong, .world-passport-heading h3, .world-passport-country-copy strong) {
  color: var(--mymappi-text-primary) !important;
}
html body main.app-shell section.map-stage.memories-focus #memoryLanePage :is(.memory-lane-empty-copy p, .memory-lane-empty-recovery summary, .world-passport-heading p, .world-passport-country-copy small) {
  color: var(--mymappi-text-muted) !important;
}
html body main.app-shell section.map-stage.memories-focus #memoryLanePage .world-passport-card {
  background: #f9fcfd !important;
  border-color: #c5d8e2 !important;
  box-shadow: 0 10px 28px #00243f09 !important;
}
html body main.app-shell section.map-stage.memories-focus #memoryLanePage .world-passport-heading-icon {
  color: var(--mymappi-text-primary) !important;
  background: #e4f5f1 !important;
}

html body #memoryLanePage :is(.memory-lane-toolbar, .memory-lane-view-tabs, .memory-lane-browse, .drawer-view) {
  box-sizing: border-box !important;
  width: 100% !important;
  max-width: var(--lane-width, 1180px) !important;
  min-width: 0 !important;
  margin-inline: auto !important;
}
html body #memoryLanePage .memory-lane-toolbar {
  display: block !important;
  position: relative !important;
  top: auto !important;
  padding: 0 !important;
  margin-bottom: 16px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}
html body #memoryLanePage .memory-hub-heading {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 12px !important;
  margin: 0 0 14px !important;
  padding: 0 !important;
  max-height: none !important;
  opacity: 1 !important;
  transform: none !important;
}
html body #memoryLanePage .memory-hub-title { display: block !important; min-width: 0 !important; text-align: left !important; }
html body #memoryLanePage .memory-hub-kicker { display: none !important; }
html body #memoryLanePage .memory-hub-title h2 {
  margin: 0 !important;
  color: #00243f !important;
  font-size: clamp(1.625rem, 2.4vw, 2rem) !important;
  line-height: 1.15 !important;
  letter-spacing: -.025em !important;
}
html body #memoryLanePage .memory-hub-title p {
  margin: 5px 0 0 !important;
  color: #526d7b !important;
  font-size: .875rem !important;
  font-weight: 500 !important;
  line-height: 1.4 !important;
}
html body #memoryLanePage #memoryCount { display: none !important; }
html body #memoryLanePage #closeMemoriesButton {
  flex: 0 0 44px !important;
  width: 44px !important;
  height: 44px !important;
  color: #00243f !important;
  background: #eaf5f3 !important;
  border: 1px solid #cfe3e1 !important;
}
html body #memoryLanePage .memory-lane-search {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  min-height: 48px !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 14px !important;
  border: 1px solid #b8d4d7 !important;
  border-radius: 14px !important;
  background: #fff !important;
  box-shadow: none !important;
  color: #496774 !important;
}
html body #memoryLanePage #searchInput {
  width: 100% !important;
  min-width: 0 !important;
  min-height: 48px !important;
  padding: 0 !important;
  margin: 0 !important;
  border: 0 !important;
  background: transparent !important;
  color: #00243f !important;
  font-size: 16px !important;
  font-weight: 500 !important;
  box-shadow: none !important;
}
html body #memoryLanePage #searchInput::placeholder { color: #607b87 !important; opacity: 1 !important; font-weight: 500 !important; }
/* Views are navigation, not a second row of filter pills. A quiet underline
   establishes the hierarchy; rem-sized columns reflow with enlarged text. */
html body #memoryLanePage .memory-lane-view-tabs {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 4.25rem), 1fr)) !important;
  gap: 2px !important;
  padding: 0 !important;
  margin-top: 0 !important;
  margin-bottom: 12px !important;
  border: 0 !important;
  border-bottom: 1px solid #cbdde2 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}
html body #memoryLanePage .memory-lane-view-tabs .tab {
  width: 100% !important;
  min-width: 0 !important;
  min-height: 44px !important;
  height: auto !important;
  margin: 0 !important;
  padding: 10px 4px !important;
  border: 1px solid transparent !important;
  border-radius: 10px 10px 0 0 !important;
  background: transparent !important;
  color: #526d7b !important;
  font-size: .8125rem !important;
  font-weight: 700 !important;
  white-space: normal !important;
  overflow-wrap: anywhere !important;
  box-shadow: none !important;
}
html body #memoryLanePage .memory-lane-view-tabs .tab.active {
  background: #f8fcfb !important;
  color: #00243f !important;
  border-color: transparent !important;
  box-shadow: inset 0 -3px #65c9b6 !important;
}
html body #memoryLanePage .memory-lane-browse { margin-bottom: 10px !important; }
html body #memoryLanePage .memory-lane-controls {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  flex-wrap: wrap !important;
  gap: 8px 16px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
}
html body #memoryLanePage .memory-lane-filter-chips {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 6px !important;
  min-width: 0 !important;
  overflow: visible !important;
}
html body #memoryLanePage .memory-lane-filter-chip {
  min-height: 44px !important;
  padding: 8px 10px !important;
  border-radius: 10px !important;
  border: 1px solid transparent !important;
  background: transparent !important;
  color: #345464 !important;
  font-size: .75rem !important;
  font-weight: 650 !important;
  box-shadow: none !important;
}
html body #memoryLanePage .memory-lane-filter-chip.is-active {
  border-color: #b8dfd5 !important;
  background: #d7f1eb !important;
  color: #00243f !important;
}
html body #memoryLanePage .memory-lane-sort {
  display: flex !important;
  align-items: center !important;
  flex: 0 0 auto !important;
  gap: 8px !important;
  min-width: 0 !important;
  width: auto !important;
  max-width: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
  color: #526d7b !important;
  font-size: 13px !important;
}
html body #memoryLanePage .memory-lane-sort select {
  min-height: 44px !important;
  height: 44px !important;
  box-sizing: border-box !important;
  width: auto !important;
  min-width: 0 !important;
  max-width: 100% !important;
  padding: 8px 28px 8px 10px !important;
  border: 1px solid #d2e3e4 !important;
  border-radius: 10px !important;
  background-color: #f8fcfb !important;
  appearance: none !important;
  -webkit-appearance: none !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23526d7b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 10 5 5 5-5'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 9px center !important;
  color: #00243f !important;
  font-size: .8125rem !important;
  font-weight: 650 !important;
}
html body #memoryLanePage :is(.memory-lane-result-line, .memory-lane-order-note) {
  color: #526d7b !important;
  font-size: 13px !important;
  line-height: 1.5 !important;
}
html body #memoryLanePage .memory-lane-result-line {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  flex-wrap: wrap !important;
  gap: 4px 8px !important;
  min-height: 44px !important;
  padding-top: 8px !important;
}
html body #memoryLanePage .memory-lane-result-line > [role="status"] { margin-right: auto; }
html body #memoryLanePage .memory-lane-result-line > .memory-lane-order-note { font-size: .75rem !important; }
html body #memoryLanePage .memory-lane-result-line button {
  min-height: 44px;
  border: 0;
  padding: 8px;
  border-radius: 10px;
  background: transparent;
  color: #00243f;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
html body #memoryLanePage .drawer-view { padding: 0 !important; }
html body #memoryLanePage > :is(#memoryList, #timelineView, #listsView, #statsView) {
  box-sizing: border-box !important;
  width: 100% !important;
  max-width: var(--lane-width, 1180px) !important;
  min-width: 0 !important;
  margin-inline: auto !important;
  padding: 0 !important;
}
html body #memoryLanePage #memoryList .memory-lane-overview {
  display: block !important;
  min-height: 0 !important;
  padding: 0 !important;
  margin: 0 0 18px !important;
  border: 0 !important;
  border-top: 1px solid #d4e3e6 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}
html body #memoryLanePage #memoryList .memory-lane-overview-footer {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  flex-wrap: wrap !important;
  gap: 0 12px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  min-height: 44px !important;
}
html body #memoryLanePage #memoryList .memory-lane-archive-status {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  min-height: 44px !important;
  box-sizing: border-box !important;
  min-width: 0 !important;
  white-space: normal !important;
  overflow-wrap: anywhere !important;
  padding: 8px 3px !important;
  color: #526d7b !important;
  font-size: 12px !important;
  line-height: 1.5 !important;
}
html body #memoryLanePage #memoryList .memory-lane-archive-status.needs-attention { color: #76551c !important; }
html body #memoryLanePage #memoryList .memory-lane-archive-status[data-backup-state="attention"] i,
html body #memoryLanePage #memoryList .memory-lane-archive-status[data-backup-state="pending"] i { background: #ab7d34 !important; box-shadow: 0 0 0 3px #ab7d341a !important; }
html body #memoryLanePage #memoryList .memory-lane-archive-status[data-backup-state="local"] i,
html body #memoryLanePage #memoryList .memory-lane-archive-status[data-backup-state="unconfirmed"] i { background: #62828e !important; box-shadow: 0 0 0 3px #62828e1a !important; }
html body #memoryLanePage #memoryList .memory-lane-tools summary { box-sizing: border-box !important; padding: 8px 0 8px 8px !important; min-height: 44px !important; display: flex !important; align-items: center !important; gap: 8px !important; color: #345464 !important; background: transparent !important; border: 0 !important; box-shadow: none !important; font-size: .75rem !important; font-weight: 650 !important; }
html body #memoryLanePage #memoryList .memory-lane-tools summary::after {
  content: ""; flex: 0 0 6px; width: 6px; height: 6px;
  border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: translateY(-2px) rotate(45deg); margin-right: 3px;
}
html body #memoryLanePage #memoryList .memory-lane-tools[open] summary::after { transform: translateY(2px) rotate(225deg); }
html body #memoryLanePage #memoryList .memory-lane-tools-panel {
  box-sizing: border-box !important;
  min-width: 0 !important;
  z-index: 35 !important;
  background: #fbfefd !important;
  border-color: #cfe0e3 !important;
}
html body main.app-shell section.map-stage.memories-focus #memoryLanePage:has(.memory-lane-tools[open]) {
  scroll-padding-bottom: calc(var(--bottom-nav-height, 84px) + env(safe-area-inset-bottom, 0px) + 24px) !important;
}
html body #memoryLanePage #memoryList .memory-lane-tool-status,
html body #memoryLanePage #memoryList .memory-lane-tool-actions {
  min-width: 0 !important;
  align-items: start !important;
}
html body #memoryLanePage #memoryList .memory-lane-tool-status > span {
  min-width: 0 !important;
  overflow-wrap: anywhere !important;
  line-height: 1.5 !important;
}
html body #memoryLanePage #memoryList .memory-lane-tool-status > span:first-child { grid-column: 1 / -1 !important; }
html body #memoryLanePage #memoryList .memory-lane-tool-actions > button {
  box-sizing: border-box !important;
  min-width: 0 !important;
  min-height: 44px !important;
  height: auto !important;
  scroll-margin-block: 12px !important;
  padding: 12px !important;
  white-space: normal !important;
  overflow-wrap: anywhere !important;
  font-size: 14px !important;
  line-height: 1.4 !important;
}

/* Keep the expanded phone disclosure in a whole row. A flex footer would
   ignore the older grid-column rule and squeeze it beside the sync status. */
@media (max-width: 760px) {
  html body #memoryLanePage #memoryList .memory-lane-overview-footer {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 4px 12px !important;
  }
  html body #memoryLanePage #memoryList .memory-lane-tools { min-width: 0 !important; }
  html body #memoryLanePage #memoryList .memory-lane-tools[open] {
    grid-column: 1 / -1 !important;
    display: block !important;
    width: 100% !important;
  }
  html body #memoryLanePage #memoryList .memory-lane-tools-panel {
    position: static !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 4px 0 12px !important;
    box-shadow: none !important;
  }
}
@media (max-width: 480px) {
  html body #memoryLanePage #memoryList .memory-lane-tool-status,
  html body #memoryLanePage #memoryList .memory-lane-tool-actions { grid-template-columns: minmax(0, 1fr) !important; }
  html body #memoryLanePage #memoryList .memory-lane-tools > summary { justify-content: space-between !important; }
}

html body #memoryLanePage #memoryList .pin-database-list.memory-journal-list {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  align-content: start !important;
  grid-auto-rows: max-content !important;
  gap: 20px !important;
  margin: 0 !important;
}
html body #memoryLanePage #memoryList article.memory-lane-card {
  display: flex !important;
  flex-direction: column !important;
  height: auto !important;
  min-height: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  transform: none !important;
  border-color: #d4e3e4 !important;
  background: #fbfefd !important;
  box-shadow: 0 8px 24px #00243f0a !important;
}
/* Intrinsic flex sections avoid WebKit retaining fractional grid-row heights
   when a two-column landscape shelf becomes one column again. */
html body #memoryLanePage #memoryList article.memory-lane-card .memory-lane-flashcard-main {
  display: flex !important;
  flex-direction: column !important;
  flex: 1 0 auto !important;
  height: auto !important;
  min-height: 0 !important;
  align-items: stretch !important;
}
html body #memoryLanePage #memoryList article.memory-lane-card .memory-lane-cover {
  flex: 0 0 auto !important;
}
html body #memoryLanePage #memoryList article.memory-lane-card .memory-lane-flashcard-copy {
  flex: 1 0 auto !important;
  height: auto !important;
}
html body #memoryLanePage #memoryList article.memory-lane-card .memory-lane-action-dock {
  flex: 0 0 auto !important;
  margin-top: auto !important;
}

/* Two aligned utility rows: collection/sort, then backup/archive. Status is
   deliberately not styled as a button; warnings remain readable in full. */
html body #memoryLanePage .memory-lane-result-line {
  padding-block: 8px 0 !important;
  margin-top: 8px !important;
  border-top: 1px solid #d4e3e6 !important;
  gap: 8px 12px !important;
}
html body #memoryLanePage .memory-lane-result-line > [role="status"] {
  color: #345464 !important;
  font-weight: 600 !important;
  font-size: .8125rem !important;
}
html body #memoryLanePage .memory-lane-sort select {
  border-radius: 12px !important;
  background-color: #fbfefd !important;
  padding-inline: 12px 30px !important;
}
html body #memoryLanePage #memoryList .memory-lane-overview-footer {
  padding-block: 6px !important;
  column-gap: 10px !important;
}
html body #memoryLanePage #memoryList .memory-lane-archive-status {
  font-weight: 500 !important;
  font-size: .75rem !important;
  padding-inline: 0 !important;
}
html body #memoryLanePage #memoryList .memory-lane-tools summary {
  padding: 10px 12px !important;
  border: 1px solid #d2e3e4 !important;
  border-radius: 12px !important;
  background: #f8fcfb !important;
  color: #00243f !important;
}
html body #memoryLanePage #memoryList .memory-lane-cover-empty {
  background-color: #00243f !important;
  background-image: url("./mymappi-mascot-wave-v4.png") !important;
  background-size: 100px auto !important;
  background-position: center 42% !important;
}
html body #memoryLanePage #memoryList .memory-lane-cover-empty > strong { color: #d3e8ed !important; }
html body #memoryLanePage #memoryList .memory-lane-cover-empty > span:not([class]) { display: none !important; }
html body #memoryLanePage #memoryList .memory-lane-card .memory-lane-flashcard-copy { padding: 18px 18px 12px !important; gap: 8px !important; }
html body #memoryLanePage #memoryList .memory-lane-card-title { color: #00243f !important; font-size: 20px !important; line-height: 1.3 !important; }
html body #memoryLanePage #memoryList .memory-lane-card-meta { color: #526d7b !important; font-size: 13px !important; line-height: 1.5 !important; }
html body #memoryLanePage #memoryList .memory-lane-note-preview { color: #345464 !important; font-size: 14px !important; line-height: 1.5 !important; }
html body #memoryLanePage .memory-sync-status {
  text-transform: none !important;
  letter-spacing: 0 !important;
  font-size: 12px !important;
  font-weight: 550 !important;
}
html body #memoryLanePage #memoryList .memory-lane-card .memory-lane-action-dock { padding: 0 18px 18px !important; }
html body #memoryLanePage #memoryList .memory-card-actions {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 44px !important;
  gap: 8px !important;
}
html body #memoryLanePage #memoryList .memory-card-actions.has-map-action { grid-template-columns: minmax(0, 1fr) 72px 44px !important; }
html body #memoryLanePage #memoryList .memory-card-actions .needs-location { grid-column: 1 / -1 !important; min-height: 44px !important; }
html body #memoryLanePage #memoryList .memory-card-actions .primary {
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  min-height: 48px !important;
  padding: 10px 8px !important;
  border-radius: 13px !important;
  background: #00243f !important;
  color: #fff !important;
  box-shadow: none !important;
}
html body #memoryLanePage #memoryList .memory-card-map-action {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  gap: 5px !important;
  width: 72px !important;
  min-width: 0 !important;
  min-height: 48px !important;
  padding: 8px !important;
  border: 1px solid #c4ddd9 !important;
  border-radius: 13px !important;
  background: #e9f5f2 !important;
  color: #00243f !important;
  box-shadow: none !important;
}
html body #memoryLanePage #memoryList .memory-card-map-action svg { width: 17px !important; height: 17px !important; }
html body #memoryLanePage #memoryList .memory-map-action-label { display: inline !important; font-size: 12px !important; font-weight: 700 !important; }
html body #memoryLanePage #memoryList .memory-lane-card-menu summary {
  min-width: 44px !important;
  width: 44px !important;
  min-height: 48px !important;
  border-radius: 13px !important;
  color: #00243f !important;
  background: #f0f6f6 !important;
}
html body #memoryLanePage :is(.memory-lane-view-intro, .memory-lane-empty, .memory-lane-no-results, .memory-lane-compact-card, .memory-lane-chapter-banner) {
  background: #fbfefd !important;
  border-color: #d4e3e4 !important;
  color: #00243f !important;
  box-shadow: 0 8px 24px #00243f08 !important;
}
html body #memoryLanePage .memory-lane-view-intro { padding: 16px 20px !important; margin-bottom: 18px !important; }
html body #memoryLanePage .memory-lane-view-intro strong { color: #00243f !important; font-size: 22px !important; }
html body #memoryLanePage :is(.primary-button, .memory-lane-compact-relive) { background: #00243f !important; color: #fff !important; }
html body #memoryLanePage :is(button, summary, [role="button"], select, input):focus-visible {
  outline: 3px solid #287ba4 !important;
  outline-offset: 3px !important;
}
html body #memoryLanePage .memory-lane-search:focus-within { outline: 2px solid #287ba4 !important; outline-offset: 2px !important; }
html body #memoryLanePage #searchInput:focus-visible { outline: none !important; }
html body #memoryLanePage :is(#timelineView, #listsView) .memory-lane-compact-card {
  display: grid !important;
  grid-template-columns: 64px minmax(0, 1fr) auto !important;
  gap: 14px !important;
  align-items: center !important;
  padding: 14px !important;
}
html body #memoryLanePage :is(#timelineView, #listsView) .memory-lane-compact-art {
  width: 64px !important;
  height: 64px !important;
  border-radius: 12px !important;
  background: #00243f !important;
}
html body #memoryLanePage :is(#timelineView, #listsView) .card-copy strong,
html body #memoryLanePage :is(#timelineView, #listsView) .card-copy small {
  display: -webkit-box !important;
  -webkit-box-orient: vertical !important;
  -webkit-line-clamp: 2 !important;
  overflow: hidden !important;
  white-space: normal !important;
  line-height: 1.4 !important;
}
html body #memoryLanePage :is(#timelineView, #listsView) .card-copy strong { font-size: 16px !important; color: #00243f !important; }
html body #memoryLanePage :is(#timelineView, #listsView) .card-copy small { font-size: 13px !important; color: #526d7b !important; }
html body #memoryLanePage :is(#timelineView, #listsView) .memory-lane-compact-relive {
  min-width: 44px !important;
  min-height: 44px !important;
  border-radius: 12px !important;
  padding: 10px 12px !important;
  font-size: 13px !important;
  box-shadow: none !important;
}

@media (max-width: 1099px) {
  html body #memoryLanePage #memoryList .pin-database-list.memory-journal-list { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  html body #memoryLanePage :is(#timelineView, #listsView) .memory-lane-compact-list { grid-template-columns: minmax(0, 1fr) !important; }
}
@media (min-width: 1000px) {
  html body #memoryLanePage .memory-lane-toolbar {
    display: grid !important;
    grid-template-columns: minmax(300px, .9fr) minmax(0, 1.1fr) !important;
    gap: 24px !important;
    align-items: center !important;
    padding-right: 78px !important;
  }
  html body #memoryLanePage .memory-hub-heading { margin: 0 !important; }
  html body #memoryLanePage .memory-hub-actions { position: absolute !important; top: 50% !important; right: 20px !important; transform: translateY(-50%) !important; }
}
@media (max-width: 699px) {
  html body #memoryLanePage :is(#timelineView, #listsView) .memory-lane-compact-card { grid-template-columns: 56px minmax(0, 1fr) 44px !important; gap: 10px !important; padding: 12px !important; }
  html body #memoryLanePage :is(#timelineView, #listsView) .memory-lane-compact-art { width: 56px !important; height: 64px !important; }
  html body #memoryLanePage :is(#timelineView, #listsView) .memory-lane-compact-relive { width: 44px !important; padding: 10px !important; }
  html body #memoryLanePage :is(#timelineView, #listsView) .memory-lane-compact-relive > span:first-child { display: none !important; }
  html body #memoryLanePage .memory-lane-toolbar { padding: 0 !important; border-radius: 0 !important; }
  html body #memoryLanePage .memory-lane-view-tabs .tab { font-size: .75rem !important; overflow-wrap: anywhere; }
  html body #memoryLanePage #memoryList .pin-database-list.memory-journal-list { grid-template-columns: minmax(0, 1fr) !important; gap: 18px !important; }
  html body #memoryLanePage .memory-lane-filter-chips { gap: 5px !important; }
  html body #memoryLanePage .memory-lane-filter-chip { padding-inline: 10px !important; font-size: .75rem !important; }
  html body #memoryLanePage #memoryList .memory-lane-tools:not([open]) { width: auto !important; }
  html body #memoryLanePage #memoryList .memory-lane-tools-panel { position: static !important; width: 100% !important; max-width: 100% !important; margin-bottom: 12px !important; }
  html body #memoryLanePage #memoryList .memory-lane-card .memory-lane-flashcard-copy { padding: 16px 14px 12px !important; }
  html body #memoryLanePage #memoryList .memory-lane-card .memory-lane-action-dock { padding: 0 14px 14px !important; }
  html body #memoryLanePage #memoryList .memory-card-actions.has-map-action { grid-template-columns: minmax(0, 1fr) 68px 44px !important; }
  html body #memoryLanePage #memoryList .memory-card-map-action { width: 68px !important; }
  html body #memoryLanePage #memoryList .memory-card-actions .primary { font-size: 13px !important; }
}
/* One archive toolbar: count + honest backup status, followed by two controls.
   The disclosure stays in flow so its tools never cover a memory or the dock. */
html body #memoryLanePage #memoryList .memory-lane-overview {
  padding: 14px 16px !important;
  border: 1px solid #d0e3e1 !important;
  border-radius: 20px !important;
  background: #f8fcfb !important;
  box-shadow: 0 5px 18px #00243f05 !important;
}
html body #memoryLanePage #memoryList .memory-lane-overview-footer {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto auto !important;
  align-items: center !important;
  gap: 12px !important;
}
html body #memoryLanePage #memoryList .memory-lane-archive-summary {
  display: grid !important;
  min-width: 0 !important;
  gap: 4px !important;
}
html body #memoryLanePage #memoryList .memory-lane-result-count {
  color: #00243f !important;
  font-size: 1rem !important;
  font-weight: 750 !important;
  line-height: 1.35 !important;
  overflow-wrap: anywhere !important;
}
html body #memoryLanePage #memoryList .memory-lane-archive-status {
  min-height: 0 !important;
  padding: 0 0 0 3px !important;
  font-size: .75rem !important;
  font-weight: 500 !important;
}
html body #memoryLanePage #memoryList .memory-lane-archive-status i { flex-shrink: 0 !important; }
html body #memoryLanePage #memoryList :is(.memory-lane-sort, .memory-lane-tools) {
  min-width: 0 !important;
  width: auto !important;
  margin: 0 !important;
}
html body #memoryLanePage #memoryList :is(.memory-lane-sort select, .memory-lane-tools summary) {
  min-height: 44px !important;
  height: auto !important;
  border: 1px solid #c8dedb !important;
  border-radius: 12px !important;
  color: #00243f !important;
  background-color: #edf6f3 !important;
  box-shadow: none !important;
  font-size: .8125rem !important;
  font-weight: 650 !important;
}
html body #memoryLanePage #memoryList .memory-lane-tools summary {
  justify-content: center !important;
  padding: 10px 12px !important;
  white-space: normal !important;
}
html body #memoryLanePage #memoryList .memory-lane-sort select {
  width: 100% !important;
  max-width: 100% !important;
  padding: 10px 30px 10px 12px !important;
}
html body #memoryLanePage #memoryList .memory-lane-tools[open] {
  grid-column: 1 / -1 !important;
  width: 100% !important;
}
html body #memoryLanePage #memoryList .memory-lane-tools[open] summary {
  width: max-content !important;
  max-width: 100% !important;
  margin-left: auto !important;
}
html body #memoryLanePage #memoryList .memory-lane-tools-panel {
  position: static !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 12px 0 0 !important;
}
html body #memoryLanePage #memoryList .memory-lane-clear-results {
  grid-column: 1 / -1 !important;
  justify-self: start !important;
  min-height: 44px !important;
  padding: 8px 12px !important;
  border: 1px solid #c8dedb !important;
  border-radius: 12px !important;
  color: #00243f !important;
  background: transparent !important;
}
@media (max-width: 600px) {
  html body #memoryLanePage #memoryList .memory-lane-overview-footer {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 12px 8px !important;
  }
  html body #memoryLanePage #memoryList .memory-lane-archive-summary { grid-column: 1 / -1 !important; }
  html body #memoryLanePage #memoryList :is(.memory-lane-sort, .memory-lane-tools:not([open])) { width: 100% !important; }
}

@media (prefers-reduced-motion: reduce) {
  html body #memoryLanePage * { scroll-behavior: auto !important; transition: none !important; }
}
