/* A photograph and its caption form one keepsake. Keep text in normal flow:
   longer titles, place names and larger type must never run into the arrow. */
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
  .today-memory-card.has-today-memory:has(> .today-memory-main.has-photo) {
  padding-bottom: var(--home-today-card-padding, 10px) !important;
}
/* Match the shared navy palette's ID specificity only for the photo frame;
   the navy no-photo fallback remains unchanged. */
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay#homeMemoryOfDay
  .today-memory-card.has-today-memory > .today-memory-main.has-photo {
  height: auto !important;
  min-height: 0 !important;
  max-height: none !important;
  background: #f3f9f8 !important;
  box-shadow: none !important;
}
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
  .today-memory-card.has-today-memory > .today-memory-main.has-photo:is(.caption-over-light, .caption-over-dark, .has-photo) .today-memory-copy {
  position: relative !important;
  inset: auto !important;
  transform: none !important;
  translate: none !important;
  width: min(620px, calc(100% - 24px)) !important;
  max-width: min(620px, calc(100% - 24px)) !important;
  height: auto !important;
  min-height: 100px !important;
  max-height: none !important;
  margin: 12px auto !important;
  padding: 16px 18px !important;
  grid-template-columns: minmax(0, 1fr) 48px !important;
  grid-template-rows: auto auto !important;
  grid-template-areas: "title action" "meta action" !important;
  gap: 7px 18px !important;
  border-radius: 20px !important;
  border-color: #d5e5e7 !important;
  background: linear-gradient(125deg, #fffefa, #f1faf8) !important;
  box-shadow: 0 6px 18px #00243f0a, inset 0 1px 0 #fff !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
  .today-memory-card.has-today-memory > .today-memory-main.has-photo .today-memory-title {
  display: -webkit-box !important;
  -webkit-box-orient: vertical !important;
  -webkit-line-clamp: 2 !important;
  white-space: normal !important;
  overflow-wrap: anywhere;
  font-size: 1.125rem !important;
  font-weight: 780 !important;
  line-height: 1.25 !important;
  color: #00243f !important;
}
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
  .today-memory-card.has-today-memory > .today-memory-main.has-photo .today-memory-meta-row > small {
  flex-direction: column !important;
  align-items: flex-start !important;
  gap: 6px !important;
  font-size: .8125rem !important;
  font-weight: 500 !important;
  line-height: 1.4 !important;
  color: #486375 !important;
}
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
  .today-memory-card.has-today-memory > .today-memory-main.has-photo .today-memory-place-date {
  display: grid !important;
  grid-template-columns: 10px minmax(0, 1fr) !important;
  gap: 3px 7px !important;
  width: 100% !important;
  white-space: normal !important;
}
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
  .today-memory-card.has-today-memory > .today-memory-main.has-photo .today-memory-place-marker {
  display: block !important;
  grid-column: 1 !important;
  grid-row: 1 !important;
}
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
  .today-memory-card.has-today-memory > .today-memory-main.has-photo .today-memory-place-text {
  grid-column: 2 !important;
  grid-row: 1 !important;
}
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
  .today-memory-card.has-today-memory > .today-memory-main.has-photo .today-memory-date-full {
  display: block !important;
  grid-column: 2 !important;
  font-weight: 500 !important;
  white-space: normal !important;
}
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
  .today-memory-card.has-today-memory > .today-memory-main.has-photo :is(.today-memory-date-compact, .today-memory-meta-separator) { display: none !important; }
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
  .today-memory-card.has-today-memory > .today-memory-main.has-photo .today-memory-relive-button,
html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
  .today-memory-card.has-today-memory > .today-memory-main.has-photo .today-memory-relive-button:is(:hover, :focus-visible, :active, .is-relive-launching) {
  position: static !important;
  inset: auto !important;
  grid-area: action !important;
  align-self: center !important;
  width: 48px !important; min-width: 48px !important; max-width: 48px !important;
  height: 48px !important; min-height: 48px !important; max-height: 48px !important;
  margin: 0 !important;
  translate: none !important;
  transform: none !important;
  background: #00243f !important;
  box-shadow: 0 4px 12px #00243f14 !important;
}
@media (orientation: landscape) and (max-height: 520px) and (hover: none) and (pointer: coarse) {
  html body main.app-shell section.map-stage.home-focus #homeDashboard #homeMemoryOfDay
    .today-memory-card.has-today-memory > .today-memory-main.has-photo .today-memory-photo {
    height: clamp(160px, 48svh, 250px) !important;
    min-height: 0 !important;
    max-height: 250px !important;
  }
}
