/* Photo location map. Map chrome is in map-shell.css.
   In-page layout (body.map-page) is in map-page.css. */

.photo-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  padding: 0.35rem 0.9rem 0.85rem;
}

.photo-dock .dock-title {
  margin: 0;
  font-size: 1rem;
  line-height: 1.3;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.photo-dock .chip {
  background: var(--surface);
}

.photo-dock .chip:hover,
.photo-dock .chip.is-active,
.photo-dock .chip[aria-pressed="true"] {
  background: var(--tint-strong);
}

.photo-dock .chip:disabled,
.photo-dock .chip:disabled:hover {
  background: var(--surface);
}

.photo-actions,
.photo-exports {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.75rem;
  align-items: center;
}

.photo-privacy {
  margin: 0.55rem 0 0;
  font-size: 0.92rem;
  line-height: 1.4;
  color: color-mix(in srgb, var(--text) 68%, transparent);
}

.photo-status {
  margin: 0.55rem 0 0;
  font-size: 0.92rem;
  line-height: 1.4;
}

.photo-status:empty {
  display: none;
}

.photo-path-toggle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.75rem 0 0;
  font-size: 0.92rem;
  cursor: pointer;
}

.photo-path-toggle input {
  width: 1.1rem;
  height: 1.1rem;
}

.photo-list {
  list-style: none;
  margin: 0.75rem 0 0;
  padding: 0;
}

.photo-list-row {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  border-top: 1px solid var(--line);
}

.photo-list li:first-child .photo-list-row {
  border-top: 0;
}

.photo-list-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  padding: 0.45rem 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  font: inherit;
}

.photo-list-item:hover,
.photo-list-item:focus-visible {
  background: var(--tint);
  outline: none;
}

.photo-thumb {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  object-fit: cover;
  background: var(--tint);
  border: 1px solid var(--line);
}

.photo-thumb--placeholder {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: color-mix(in srgb, var(--text) 45%, transparent);
  font-size: 0.7rem;
  font-weight: 650;
}

.photo-meta {
  flex: 1 1 auto;
  min-width: 0;
}

.photo-name {
  display: block;
  font-size: 0.92rem;
  font-weight: 650;
  line-height: 1.3;
  word-break: break-word;
}

.photo-date {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.82rem;
  color: color-mix(in srgb, var(--text) 68%, transparent);
}

.photo-remove {
  flex: 0 0 auto;
  margin-left: auto;
}

.photo-nogps-wrap {
  margin-top: 1rem;
}

.photo-nogps-title {
  margin: 0 0 0.35rem;
  font-size: 0.95rem;
  font-weight: 700;
}

.photo-marker-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  overflow: hidden;
  border: 2px solid var(--surface);
  box-shadow: 0 1px 4px color-mix(in srgb, var(--text) 28%, transparent);
  background: var(--tint);
}

.photo-marker-icon img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-popup {
  min-width: 12rem;
  max-width: 16rem;
}

.photo-popup-thumb {
  display: block;
  width: 100%;
  max-height: 140px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 0.5rem;
  background: var(--tint);
}

.photo-popup-name {
  margin: 0 0 0.35rem;
  font-weight: 700;
  word-break: break-word;
}

.photo-popup-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0.35rem 0 0;
  font-size: 0.88rem;
  line-height: 1.35;
}

.photo-popup-k {
  display: block;
  font-size: 0.8rem;
  font-weight: 650;
  color: color-mix(in srgb, var(--text) 68%, transparent);
}

.photo-popup-v {
  font-family: var(--font-mono);
  word-break: break-word;
}

/* Cluster bubbles: brand tokens, no heavy coloured borders. */
.marker-cluster {
  background: color-mix(in srgb, var(--brand) 22%, transparent);
}

.marker-cluster div {
  background: color-mix(in srgb, var(--brand) 72%, transparent);
  color: #fff;
  font-weight: 700;
}

.marker-cluster-small,
.marker-cluster-medium,
.marker-cluster-large {
  background: color-mix(in srgb, var(--brand) 22%, transparent);
}

.marker-cluster-small div,
.marker-cluster-medium div,
.marker-cluster-large div {
  background: color-mix(in srgb, var(--brand) 72%, transparent);
}

@media (max-width: 720px) {
  body.is-map .map-app:has(.photo-dock) .leaflet-bottom.leaflet-right {
    top: auto;
    bottom: 0;
  }
}
