/* Final, scoped brand paint for memory utilities. Photos, emotions, destructive
   actions and the map style keep their own colors. No visibility overrides. */
/* The legacy photo-containment rules paint the image itself as well as its
   frame. Replace their shared paint without changing fit, crop or focal point. */
html body main.app-shell { --mymappi-media-frame: #00243f; }

/* The full chapter viewer has its own media frames and caption strip; it
   does not inherit the Home chapter-card palette. Never recolor the photos. */
html body main.app-shell #lifeChapterViewer .life-chapter-viewer-panel {
  background: #f3f8fa !important; color: #00243f !important; border-color: #bfd8dd !important;
  scrollbar-color: #8ba6b8 transparent !important;
}
html body main.app-shell #lifeChapterViewer .life-chapter-viewer-backdrop { background: #00243fa8 !important; }
html body main.app-shell #lifeChapterViewer :is(#lifeChapterViewerTitle, .life-chapter-viewer-gallery-heading > span, .life-chapter-viewer-counter strong) { color: #00243f !important; }
html body main.app-shell #lifeChapterViewer :is(.life-chapter-viewer-meta, .life-chapter-viewer-gallery-heading > small, .life-chapter-viewer-private, .life-chapter-viewer-counter) { color: #4c6977 !important; }
html body main.app-shell #lifeChapterViewer :is(.life-chapter-viewer-meta svg, .life-chapter-viewer-private svg) { color: #00243f !important; }
html body main.app-shell #lifeChapterViewer .life-chapter-viewer-eyebrow {
  color: #00243f !important; background: #e4f5f1 !important; border-color: #bfd8dd !important;
}
html body main.app-shell #lifeChapterViewer :is(.life-chapter-viewer-media, .life-chapter-viewer-media-art, .life-chapter-viewer-media-art > img, .life-chapter-viewer-media-caption) {
  background: var(--mymappi-media-frame) !important;
  color: #fff !important;
  border-color: #366079 !important;
}
html body main.app-shell #lifeChapterViewer .life-chapter-viewer-media-caption > small { color: #c7dae4 !important; }
html body main.app-shell #lifeChapterViewer .life-chapter-viewer-media.is-current {
  border-color: #75d9c3 !important;
  box-shadow: 0 0 0 2px #75d9c333 !important;
}
html body main.app-shell #lifeChapterViewer .life-chapter-viewer-moments {
  color: #fff !important; background: #00243f !important; border-color: #366079 !important;
  box-shadow: none !important;
}
html body main.app-shell #lifeChapterViewer :is(.life-chapter-viewer-edit, .life-chapter-viewer-gallery-nav, .life-chapter-viewer-close) {
  color: #00243f !important; background: #f9fcfd !important; border-color: #bfd8dd !important;
}
html body main.app-shell #lifeChapterViewer .life-chapter-viewer-dot[aria-current="true"] { background: #75d9c3 !important; }

html body main.app-shell section.map-stage #ourMapExplorerButton {
  color: #fff !important;
  background: #00243f !important;
  border-color: #366079 !important;
  box-shadow: 0 10px 28px #00243f30 !important;
}
html body #ourMapExplorerButton .our-map-explorer-mappi {
  background: transparent !important; border-color: transparent !important; box-shadow: none !important;
}
html body #ourMapExplorerButton .our-map-explorer-copy strong { color: #fff !important; }
html body #ourMapExplorerButton .our-map-explorer-copy small { color: #75d9c3 !important; }
html body #ourMapExplorerButton .our-map-explorer-chevron { color: #00243f !important; background: #75d9c3 !important; }

html body main.app-shell #memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation.memory-save-confirmation[data-kind="success"] {
  color: #fff !important; background: #00243f !important; border-color: #366079 !important;
  box-shadow: 0 10px 28px #00243f30 !important;
}
html body main.app-shell #memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation.memory-save-confirmation[data-kind="success"]::before { background: #75d9c3 !important; }
html body main.app-shell #memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation.memory-save-confirmation[data-kind="success"] > span { color: #75d9c3 !important; background: #10334a !important; }
html body main.app-shell #memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation.memory-save-confirmation[data-kind="success"] strong { color: #fff !important; }
html body main.app-shell #memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation.memory-save-confirmation[data-kind="success"] small { color: #c7dae4 !important; }
html body main.app-shell #memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation.memory-save-confirmation[data-kind="success"] .memory-confirmation-status { color: #75d9c3 !important; background: #10334a !important; }
html body main.app-shell #memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation.memory-save-confirmation[data-kind="success"] .memory-confirmation-view {
  color: #00243f !important; background: #75d9c3 !important; border-color: #75d9c3 !important; box-shadow: none !important;
}
html body main.app-shell #memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation#memorySaveConfirmation.memory-save-confirmation[data-kind="success"] :is(.memory-confirmation-secondary, .memory-confirmation-done) {
  color: #fff !important; background: #10334a !important; border-color: #557285 !important; box-shadow: none !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-heart-confirmation.is-success {
  color: #fff !important; background: #00243f !important; border-color: #75d9c3 !important; box-shadow: 0 8px 24px #00243f30 !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule :is(.memory-capsule-visual, .memory-capsule-cover-media, .memory-capsule-cover-gallery, .memory-capsule-cover-slide, .memory-capsule-cover-placeholder) {
  background: #00243f !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-inside-heading h3 {
  margin: 0 !important; color: #00243f !important; font-size: 12px !important; letter-spacing: .12em; text-transform: uppercase;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-inside-card header > :first-child {
  color: #00243f !important; background: #e4f5f1 !important;
}
/* Capsule details have their own legacy styles, separate from the editor and
   full-screen player. Keep these nested accents on the same brand palette. */
html body main.app-shell #memoryBottomSheet .full-memory-capsule :is(.memory-capsule-inside-card, .memory-capsule-video-shelf) {
  background: #f9fcfd !important; border-color: #c8dce4 !important;
  box-shadow: none !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule :is(.memory-capsule-inside-card header strong, .memory-capsule-video-heading strong, .memory-capsule-video-copy strong) {
  color: #00243f !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule :is(.memory-capsule-inside-card header small, .memory-capsule-video-heading small, .memory-capsule-video-copy small) {
  color: #4c6977 !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule :is(.memory-capsule-atmosphere > div > span, .memory-capsule-video-heading-icon) {
  color: #00243f !important; background: #e4f5f1 !important; border-color: #bfd8dd !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule :is(.memory-capsule-atmosphere > div svg, .memory-capsule-video-arrow) {
  color: #00243f !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-video-preview {
  color: #00243f !important; background: #fff !important; border-color: #c8dce4 !important;
  box-shadow: 0 8px 20px #00243f0d !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-video-preview:is(:hover, :focus-visible) {
  border-color: #366079 !important; box-shadow: 0 10px 24px #00243f1a !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-video-preview:focus-visible {
  outline-color: #75d9c3 !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-video-art {
  background: #00243f !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-video-art-shade {
  background: linear-gradient(145deg, #00243f00, #00243f66) !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-video-play {
  color: #00243f !important; background: #75d9c3 !important; border-color: #75d9c3 !important;
  box-shadow: 0 8px 20px #00243f30 !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-video-art > small {
  color: #fff !important; background: #00243fe6 !important; border-color: #557285 !important;
}
/* The sound card is intentionally dark; do not inherit light-card text. */
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-soundscape {
  color: #fff !important; background: #00243f !important; border-color: #366079 !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-soundscape :is(header strong, .memory-capsule-voice-heading strong, .memory-capsule-song strong) {
  color: #fff !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-soundscape :is(header small, .memory-capsule-voice-heading small, .memory-capsule-song small) {
  color: #c7dae4 !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-soundscape :is(.memory-capsule-song > svg, .memory-capsule-voice-icon) {
  color: #75d9c3 !important; background: #10334a !important;
}
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-soundscape .memory-capsule-song { border-color: #366079 !important; }
html body main.app-shell #memoryBottomSheet .full-memory-capsule .memory-capsule-audio-start {
  color: #00243f !important; background: #75d9c3 !important; border-color: #75d9c3 !important;
}

html body main.app-shell section.map-stage #memoryForm#memoryForm :is(#editorMode, .memory-flow-step, .memory-flow-substep) {
  color: #00243f !important; background: #e4f5f1 !important; border-color: #bfd8dd !important;
}
/* Trip membership is informational. Preserve its name, link and hidden state. */
html body main.app-shell #memoryForm #activeTripEditorChip {
  color: #00243f !important; background: #e4f5f1 !important;
  border-color: #bfd8dd !important; box-shadow: none !important;
}
html body main.app-shell #memoryForm #activeTripEditorChip::before {
  background: #00243f !important; box-shadow: none !important;
}
html body main.app-shell #memoryForm #activeTripEditorChip svg { color: #00243f !important; }
html body main.app-shell section.map-stage #memoryForm#memoryForm :is(.memory-inside-moment-editor, .memory-sound-capture) {
  color: #00243f !important; background: #f9fcfd !important; border-color: #c8dce4 !important;
  box-shadow: 0 8px 20px #00243f0d !important;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-inside-moment-editor::before { background: #00243f !important; }
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-inside-moment-editor > summary > span,
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-sound-capture-heading strong { color: #00243f !important; }
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-inside-moment-editor > summary > span::before,
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-inside-moment-editor > summary > small,
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-sound-capture-heading small { color: #4c6977 !important; }
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-inside-moment-editor > summary::after,
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-sound-capture > summary::after,
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-sound-capture-icon {
  color: #fff !important; background: #00243f !important; box-shadow: none !important;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-media-preview .memory-media-video {
  color: #fff !important; background: #00243f !important; border-color: #366079 !important; box-shadow: none !important;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-media-preview .memory-media-video.is-cover {
  border-color: #75d9c3 !important; box-shadow: 0 0 0 2px #75d9c333 !important;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-media-thumb-image {
  background: #00243f !important;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-editor-cover-preview,
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-editor-cover-preview > img,
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-media-video.is-pending > img {
  background: #00243f !important;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-media-thumb.is-cover .memory-media-thumb-image {
  border-color: #75d9c3 !important;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-editor-cover-tools {
  position: absolute;
  bottom: 12px;
  left: 12px;
  right: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  pointer-events: none;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-editor-cover-tools .memory-editor-cover-preview-copy {
  position: static;
  flex: 0 0 32px;
  box-shadow: none;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-editor-cover-focus {
  /* Quiet photo-overlay action: a full touch target without a large pill or
     inherited icon sizing. Keep the photo visible and the label readable. */
  position: static;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: max-content;
  max-width: calc(100% - 40px);
  min-width: 44px;
  min-height: 44px;
  margin: 0;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.8) !important;
  border-radius: 14px;
  color: #00243f !important;
  background: rgba(255, 255, 255, 0.96) !important;
  box-shadow: 0 2px 8px rgba(0, 36, 63, 0.14);
  font-size: 0.8125rem;
  font-weight: 650;
  line-height: 1.25;
  letter-spacing: 0;
  text-align: center;
  white-space: normal;
  pointer-events: auto;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  transition: background-color 140ms ease, box-shadow 140ms ease;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-editor-cover-focus :is([data-icon], svg) {
  flex: 0 0 18px;
  width: 18px !important;
  height: 18px !important;
  min-width: 18px !important;
  max-width: 18px !important;
  min-height: 18px !important;
  max-height: 18px !important;
  stroke-width: 1.8;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-editor-cover-focus:focus:not(:focus-visible) {
  outline: none;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-editor-cover-focus:focus-visible {
  outline: 2px solid #00243f !important;
  outline-offset: 2px;
  box-shadow: 0 0 0 4px #fff;
}
html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-editor-cover-focus:active {
  background: #e8f5f2 !important;
}
@media (hover: hover) and (pointer: fine) {
  html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-editor-cover-focus:hover {
    background: #f0faf7 !important;
    box-shadow: 0 3px 10px rgba(0, 36, 63, 0.18);
  }
}
@media (prefers-reduced-motion: reduce) {
  html body main.app-shell section.map-stage #memoryForm#memoryForm .memory-editor-cover-focus {
    transition: none;
  }
}
/* The cover picker is a top-layer dialog outside .app-shell. */
html body .memory-cover-picker,
html body .memory-cover-picker footer { background: #f9fcfd; }
html body .memory-cover-picker-grid img { background: #00243f !important; }
html body .memory-cover-picker button:focus-visible { outline-color: #366079; }
html body main.app-shell #photoLightbox .photo-lightbox-video-actions {
  background: #00243f !important; border-color: #366079 !important;
}
html body main.app-shell #photoLightbox #photoLightboxPlayInline {
  background: #75d9c3 !important; color: #00243f !important; border-color: #75d9c3 !important; box-shadow: none !important;
}
html body main.app-shell #photoLightbox #photoLightboxOpenVideo {
  background: #10334a !important; color: #fff !important; border-color: #557285 !important; box-shadow: none !important;
}
