/**
 * public/css/components/photo-sort.css
 * Canopy v2 component — the Photos tab header: sort button, large title, view switch (#546, #626).
 * The sort control is a round glass button in the top bar (.photo-sort.glass-btn.glass, glass.css)
 * with a transparent native <select> laid over it, so a tap opens the platform picker
 * (iOS wheel) with the sort choices. It shows on the Photos tab only.
 * Consumes ONLY --v2-* tokens.
 */

.photo-sort { position: relative; }
.app-topbar:not([data-view="photos"]) .photo-sort { display: none; }

.photo-sort-icon {
  width: 20px;
  height: 20px;
  pointer-events: none;
}

.photo-sort-select {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: inherit;
  opacity: 0;
  cursor: pointer;
  /* 16px stops iOS zooming the page when the select takes focus. */
  font-size: 16px;
  -webkit-appearance: none;
  appearance: none;
}

.photo-sort:has(.photo-sort-select:focus-visible) {
  outline: 2px solid var(--v2-focus-ring);
  outline-offset: 2px;
}

/* Large title: collapses into the glass bar once scrolled. Sits on the same 16px
   inset as the timeline below it. */
.photos-header { padding: var(--v2-space-xs) 0 var(--v2-space-md); }
.photos-title {
  margin: 0;
  font-family: var(--v2-font-display);
  font-weight: 700;
  font-size: var(--v2-font-size-display);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--v2-text-primary);
}
.photos-count {
  display: block;
  margin-top: 2px;
  font-size: var(--v2-font-size-footnote);
  font-weight: 500;
  color: var(--v2-text-tertiary);
  font-variant-numeric: tabular-nums;
}

/* Timeline / By Plant: the glass switch at the top of the content; it scrolls with it. */
.photos-seg { padding: var(--v2-space-xs) 0 var(--v2-space-sm); }
