.photoprism-app {
  --photoprism-surface: rgba(255, 255, 255, 0.82);
  --photoprism-surface-strong: rgba(255, 255, 255, 0.94);
  --photoprism-line: rgba(148, 163, 184, 0.28);
  --photoprism-line-strong: rgba(var(--photoprism-accent-rgb, 249, 115, 22), 0.42);
  --photoprism-text: #1e293b;
  --photoprism-text-muted: #64748b;
  --photoprism-accent: #f97316;
  --photoprism-accent-rgb: 249, 115, 22;
  --photoprism-accent-deep: #9a3412;
  --photoprism-accent-contrast: #fff7ed;
  --photoprism-accent-soft: rgba(249, 115, 22, 0.12);
  --photoprism-panel-soft: rgba(255, 247, 237, 0.92);
  --photoprism-panel-strong: rgba(255, 251, 246, 0.96);
  --photoprism-glow-left: rgba(253, 186, 116, 0.4);
  --photoprism-glow-right: rgba(125, 211, 252, 0.32);
  --photoprism-bg-start: #fff9f1;
  --photoprism-bg-end: #eef6ff;
  --photoprism-viewer-shell-top: #f7fbff;
  --photoprism-viewer-shell-mid: #edf4fb;
  --photoprism-viewer-shell-bottom: #e1ebf5;
  --photoprism-viewer-surface: #ffffff;
  --photoprism-viewer-surface-strong: #f5f9fd;
  --photoprism-viewer-surface-soft: #e8f1fa;
  --photoprism-viewer-text: #18324a;
  --photoprism-viewer-text-muted: #49657f;
  --photoprism-viewer-text-subtle: #69849c;
  --photoprism-viewer-line: #cad7e5;
  --photoprism-viewer-line-strong: #8fb7dc;
  --photoprism-viewer-accent: #dcecff;
  --photoprism-viewer-accent-deep: #b8d7f5;
  --photoprism-viewer-control-surface: #ffffff;
  --photoprism-viewer-control-surface-hover: #eef6fd;
  --photoprism-viewer-control-surface-active: #e2eefb;
  --photoprism-viewer-control-text: #17324c;
  --photoprism-viewer-stage-top: #dbe7f2;
  --photoprism-viewer-stage-bottom: #c4d3df;
  --photoprism-viewer-media-surface: #f8fbff;
  --photoprism-viewer-rail-surface: #edf4fb;
  --photoprism-viewer-shadow-rgb: 125, 163, 199;
  --photoprism-shadow: 0 24px 60px rgba(148, 163, 184, 0.2);
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  color: var(--photoprism-text);
  background:
    radial-gradient(circle at top left, var(--photoprism-glow-left), transparent 24%),
    radial-gradient(circle at top right, var(--photoprism-glow-right), transparent 26%),
    linear-gradient(180deg, var(--photoprism-bg-start) 0%, var(--photoprism-bg-end) 100%);
  isolation: isolate;
}

.photoprism-app--embedded {
  position: relative;
  inset: auto;
  min-height: 100%;
  height: 100%;
}

.photoprism-app::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.06) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.9), transparent 100%);
  pointer-events: none;
}

.photoprism-app__topbar {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--photoprism-line);
  background: color-mix(in srgb, var(--photoprism-panel-strong) 92%, white);
  backdrop-filter: blur(18px);
}

.photoprism-app__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.photoprism-app__brand .ant-btn,
.photoprism-app__actions .ant-btn {
  color: var(--photoprism-text);
}

.photoprism-app__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.photoprism-app__back-button.ant-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 40px;
  min-width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  color: #0f172a;
  background: linear-gradient(135deg, rgba(239, 246, 255, 0.96), rgba(224, 242, 254, 0.92));
  box-shadow:
    0 10px 22px rgba(14, 116, 144, 0.14),
    inset 0 0 0 1px rgba(125, 211, 252, 0.32);
  -webkit-tap-highlight-color: transparent;
  -webkit-text-fill-color: currentColor;
  touch-action: manipulation;
  transition:
    color 140ms ease,
    background-color 140ms ease,
    box-shadow 140ms ease,
    transform 140ms ease;
}

.photoprism-app__back-button.ant-btn > span,
.photoprism-app__back-button.ant-btn .ant-btn-icon,
.photoprism-app__back-button.ant-btn .anticon,
.photoprism-app__back-button.ant-btn .anticon svg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  vertical-align: middle;
}

.photoprism-app__back-button.ant-btn .ant-btn-icon,
.photoprism-app__back-button.ant-btn .anticon {
  color: inherit;
  font-size: 18px;
}

.photoprism-app__back-button.ant-btn .anticon svg {
  fill: currentColor;
  stroke: currentColor;
}

.photoprism-app__exit-button.ant-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 22px rgba(148, 163, 184, 0.14);
}

.photoprism-app__back-button.ant-btn:hover,
.photoprism-app__back-button.ant-btn:focus,
.photoprism-app__back-button.ant-btn:focus-visible,
.photoprism-app__back-button.ant-btn:active,
.photoprism-app__back-button.ant-btn.ant-btn-text:not(:disabled):not(.ant-btn-disabled):active {
  color: #0369a1;
  background: linear-gradient(135deg, rgba(224, 242, 254, 0.98), rgba(186, 230, 253, 0.9));
  box-shadow:
    0 14px 28px rgba(14, 116, 144, 0.2),
    inset 0 0 0 1px rgba(125, 211, 252, 0.44);
}

.photoprism-app__back-button.ant-btn:active,
.photoprism-app__back-button.ant-btn.ant-btn-text:not(:disabled):not(.ant-btn-disabled):active {
  transform: scale(0.97);
}

.photoprism-app__brand strong,
.photoprism-app__viewer-meta strong,
.photoprism-app__photo-meta strong {
  display: block;
  font-family: 'Georgia', 'Times New Roman', serif;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.photoprism-app__brand span,
.photoprism-app__viewer-meta span,
.photoprism-app__photo-meta span,
.photoprism-app__toolbar-left span {
  color: var(--photoprism-text-muted);
}

.photoprism-app__actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.photoprism-app__login-shell {
  position: relative;
  z-index: 1;
  display: grid;
  min-height: 100%;
  height: 100%;
  min-width: 0;
  place-items: center;
  padding: 24px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.photoprism-app__login-card {
  width: min(420px, 100%);
  padding: 22px;
  border: 1px solid var(--photoprism-line);
  border-radius: 28px;
  background: var(--photoprism-surface-strong);
  box-shadow: var(--photoprism-shadow);
  backdrop-filter: blur(16px);
}

@media (max-height: 760px) {
  .photoprism-app__login-shell {
    align-content: start;
    justify-items: stretch;
    padding-block: 16px 24px;
  }

  .photoprism-app__login-card {
    margin-block: auto;
  }
}

.photoprism-app__login-card .ant-form-item {
  margin-bottom: 12px;
}

.photoprism-app__login-card .ant-input-affix-wrapper,
.photoprism-app__login-card .ant-input,
.photoprism-app__search .ant-input-affix-wrapper {
  border-radius: 16px;
  border-color: rgba(148, 163, 184, 0.24);
  color: var(--photoprism-text);
  background: rgba(255, 255, 255, 0.9);
}

.photoprism-app__login-card .ant-input::placeholder,
.photoprism-app__search .ant-input::placeholder {
  color: rgba(100, 116, 139, 0.7);
}

.photoprism-app__login-card .ant-input-password-icon {
  color: rgba(100, 116, 139, 0.9);
}

.photoprism-app__login-card .ant-btn-primary {
  height: 48px;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--photoprism-accent) 74%, white), var(--photoprism-accent));
  box-shadow: 0 14px 34px rgba(var(--photoprism-accent-rgb), 0.24);
}

.photoprism-app__login-memory {
  margin-bottom: 16px;
}

.photoprism-app__memory-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--photoprism-text-muted);
  cursor: pointer;
}

.photoprism-app__workspace {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: 0;
}

.photoprism-app__sidebar {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 0;
  padding: 16px 14px 18px;
  border-right: 1px solid var(--photoprism-line);
  background: color-mix(in srgb, var(--photoprism-panel-soft) 82%, white);
  backdrop-filter: blur(16px);
}

.photoprism-app__sidebar-backdrop {
  position: absolute;
  inset: 0;
  z-index: 3;
  border: 0;
  background: rgba(15, 23, 42, 0.46);
}

.photoprism-app__search .ant-input {
  color: inherit;
}

.photoprism-app__album-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 0;
  overflow: auto;
}

.photoprism-app__album-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 16px;
  color: var(--photoprism-text);
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.photoprism-app__album-item--active {
  border-color: var(--photoprism-line-strong);
  color: var(--photoprism-accent-deep);
  background: linear-gradient(135deg, rgba(var(--photoprism-accent-rgb), 0.18), color-mix(in srgb, var(--photoprism-panel-strong) 84%, white));
  box-shadow:
    inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.14),
    0 10px 22px rgba(var(--photoprism-accent-rgb), 0.12);
}

.photoprism-app__filter-sheet-summary {
  display: grid;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid rgba(var(--photoprism-accent-rgb), 0.12);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.32);
}

.photoprism-app__filter-sheet-summary-copy {
  display: grid;
  gap: 2px;
}

.photoprism-app__filter-sheet-summary-copy strong {
  font-size: 13px;
  color: var(--photoprism-accent-deep);
}

.photoprism-app__filter-sheet-summary-copy span {
  font-size: 11px;
  color: var(--photoprism-text-muted);
}

.photoprism-app__filter-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.photoprism-app__filter-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  color: var(--photoprism-text-muted);
  background: rgba(241, 245, 249, 0.82);
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.16);
  font-size: 11px;
  font-weight: 600;
}

.photoprism-app__filter-chip--active {
  color: var(--photoprism-accent-deep);
  background: rgba(var(--photoprism-accent-rgb), 0.14);
  box-shadow: inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.22);
}

.photoprism-app__filter-reset.ant-btn {
  justify-self: flex-start;
  min-height: 30px;
  padding-inline: 0;
  color: var(--photoprism-accent);
}

.photoprism-app__filter-sheet-mobile {
  display: grid;
  gap: 10px;
  min-height: 0;
  overflow-y: auto;
  padding-right: 2px;
  padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 4px);
}

.photoprism-app__filter-sheet-current {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 48px;
  padding: 0 14px;
  border-radius: 16px;
  color: var(--photoprism-accent-deep);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.12);
}

.photoprism-app__filter-sheet-current span {
  font-size: 12px;
  color: var(--photoprism-text-muted);
}

.photoprism-app__filter-sheet-current strong {
  max-width: 68%;
  overflow: hidden;
  color: var(--photoprism-text);
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 15px;
  font-weight: 600;
}

.photoprism-app__filter-group {
  display: grid;
  gap: 8px;
  padding: 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.08);
}

.photoprism-app__filter-group--static {
  gap: 10px;
  padding: 12px;
}

.photoprism-app__filter-group-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}

.photoprism-app__filter-group-heading-value {
  flex: 0 1 auto;
  min-width: 0;
  color: var(--photoprism-accent-deep);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
  text-align: right;
}

.photoprism-app__filter-group-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  min-height: 54px;
  padding: 0 14px;
  border: 0;
  border-radius: 14px;
  color: var(--photoprism-text);
  background: color-mix(in srgb, var(--photoprism-panel-soft) 94%, white);
  text-align: left;
}

.photoprism-app__filter-group-label {
  font-size: 15px;
  font-weight: 500;
}

.photoprism-app__filter-group-value {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: var(--photoprism-accent-deep);
}

.photoprism-app__filter-group-value strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14px;
  font-weight: 600;
}

.photoprism-app__filter-group-value .anticon {
  font-size: 12px;
  color: rgba(var(--photoprism-accent-rgb), 0.72);
  transition: transform 140ms ease;
}

.photoprism-app__filter-group--open .photoprism-app__filter-group-value .anticon {
  transform: rotate(180deg);
}

.photoprism-app__filter-group-body {
  display: grid;
  gap: 10px;
  padding: 0 4px 4px;
}

.photoprism-app__filter-group-body--fields {
  grid-template-columns: minmax(0, 1fr);
}

.photoprism-app__filter-group-body--fields .ant-input,
.photoprism-app__filter-group-body--fields .ant-input-affix-wrapper,
.photoprism-app__filter-group-body--fields .ant-select,
.photoprism-app__filter-group-body--fields .ant-select-selector,
.photoprism-app__filter-group-body--fields .ant-segmented {
  width: 100%;
  border-radius: 14px;
}

.photoprism-app__filter-group-body--fields .ant-input,
.photoprism-app__filter-group-body--fields .ant-input-affix-wrapper,
.photoprism-app__filter-group-body--fields .ant-select-selector {
  min-height: 40px;
  border-color: rgba(148, 163, 184, 0.24);
  background: rgba(255, 255, 255, 0.94);
}

.photoprism-app__filter-group-body--fields .ant-select-selector {
  padding-block: 4px;
  box-shadow: none;
}

.photoprism-app__filter-group-body--fields .ant-select-selection-placeholder,
.photoprism-app__filter-group-body--fields .ant-select-selection-search-input,
.photoprism-app__filter-group-body--fields .ant-select-selection-item {
  font-size: 14px;
}

.photoprism-app__filter-group-body--fields .ant-input:hover,
.photoprism-app__filter-group-body--fields .ant-input-affix-wrapper:hover,
.photoprism-app__filter-group-body--fields .ant-select:hover .ant-select-selector,
.photoprism-app__filter-group-body--fields .ant-select-focused .ant-select-selector,
.photoprism-app__filter-group-body--fields .ant-input-affix-wrapper-focused,
.photoprism-app__filter-group-body--fields .ant-input:focus {
  border-color: rgba(var(--photoprism-accent-rgb), 0.42);
  box-shadow: 0 0 0 2px rgba(var(--photoprism-accent-rgb), 0.08);
}

.photoprism-app__filter-group-body--fields .ant-select-multiple .ant-select-selection-item {
  background: rgba(var(--photoprism-accent-rgb), 0.12);
  border-color: rgba(var(--photoprism-accent-rgb), 0.18);
  color: var(--photoprism-accent-deep);
}

.photoprism-app__filter-field-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--photoprism-accent-deep);
}

.photoprism-app__filter-group-body .ant-segmented {
  padding: 4px;
  border-radius: 16px;
  background: rgba(255, 248, 241, 0.92);
}

.photoprism-app__filter-group-body .ant-segmented-item {
  color: var(--photoprism-text-muted);
}

.photoprism-app__filter-group-body .ant-segmented-item-selected {
  color: var(--photoprism-accent-contrast);
  background: linear-gradient(135deg, color-mix(in srgb, var(--photoprism-accent) 78%, white), var(--photoprism-accent));
  box-shadow: 0 10px 20px rgba(var(--photoprism-accent-rgb), 0.18);
}

.photoprism-app__filter-group-body--albums .photoprism-app__album-list {
  display: grid;
  grid-auto-flow: row;
  grid-auto-columns: none;
  overflow: auto;
  max-height: min(38dvh, 320px);
}

.photoprism-app__filter-group-body--options {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.photoprism-app__filter-option {
  min-height: 42px;
  border: 0;
  border-radius: 14px;
  color: var(--photoprism-text);
  background: rgba(255, 248, 241, 0.96);
  font-size: 13px;
  font-weight: 600;
}

.photoprism-app__filter-option--active {
  color: var(--photoprism-accent-contrast);
  background: linear-gradient(135deg, color-mix(in srgb, var(--photoprism-accent) 78%, white), var(--photoprism-accent));
  box-shadow: 0 14px 24px rgba(var(--photoprism-accent-rgb), 0.24);
}

.photoprism-app__filter-group-body--theme {
  display: grid;
  gap: 10px;
}

.photoprism-app__theme-preview-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(var(--photoprism-accent-rgb), 0.16), rgba(255, 255, 255, 0.92)),
    color-mix(in srgb, var(--photoprism-panel-soft) 86%, white);
  box-shadow:
    inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.14),
    0 14px 32px rgba(var(--photoprism-accent-rgb), 0.14);
}

.photoprism-app__theme-preview-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.photoprism-app__theme-preview-copy span {
  font-size: 11px;
  font-weight: 700;
  color: var(--photoprism-accent-deep);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.photoprism-app__theme-preview-copy strong {
  font-size: 16px;
  color: var(--photoprism-text);
}

.photoprism-app__theme-preview-copy p {
  margin: 0;
  font-size: 12px;
  line-height: 1.45;
  color: var(--photoprism-text-muted);
}

.photoprism-app__theme-preview-swatch {
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  border-radius: 18px;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.42),
    0 12px 24px rgba(var(--photoprism-accent-rgb), 0.22);
}

.photoprism-app__theme-chip-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
}

.photoprism-app__theme-chip {
  display: inline-grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-height: 56px;
  padding: 10px 12px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 18px;
  color: var(--photoprism-text);
  background: rgba(255, 255, 255, 0.92);
  font-size: 12px;
  font-weight: 600;
  text-align: left;
}

.photoprism-app__theme-chip--active {
  border-color: rgba(var(--photoprism-accent-rgb), 0.36);
  color: var(--photoprism-accent-deep);
  background: rgba(var(--photoprism-accent-rgb), 0.12);
  box-shadow:
    inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.14),
    0 12px 24px rgba(var(--photoprism-accent-rgb), 0.16);
}

.photoprism-app__theme-chip-swatch {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.42);
}

.photoprism-app__theme-chip-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.photoprism-app__theme-chip-copy strong {
  font-size: 12px;
  color: inherit;
}

.photoprism-app__theme-chip-copy small {
  display: block;
  overflow: hidden;
  color: var(--photoprism-text-muted);
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 10px;
  font-weight: 500;
}

.photoprism-app__filter-sheet-footer {
  position: sticky;
  bottom: 0;
  z-index: 2;
  padding-top: 8px;
  padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 4px);
  background: linear-gradient(180deg, rgba(255, 252, 248, 0), color-mix(in srgb, var(--photoprism-panel-strong) 96%, white) 26%);
}

.photoprism-app__filter-sheet-apply.ant-btn {
  width: 100%;
  min-height: 46px;
  border: 0;
  border-radius: 999px;
  font-weight: 700;
  background: linear-gradient(135deg, color-mix(in srgb, var(--photoprism-accent) 78%, white), var(--photoprism-accent));
  box-shadow: 0 18px 34px rgba(var(--photoprism-accent-rgb), 0.24);
}

.photoprism-app__main {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}

.photoprism-app__toolbar {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
  padding: 10px 12px 8px;
}

.photoprism-app__toolbar-search {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
}

.photoprism-app__toolbar-preview-switch .ant-segmented {
  padding: 2px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.18);
}

.photoprism-app__toolbar-preview-switch .ant-segmented-item-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  min-height: 28px;
  padding-inline: 7px;
  font-size: 0;
}

.photoprism-app__toolbar-preview-switch .ant-segmented-item-label .anticon {
  font-size: 13px;
}

.photoprism-app__search--toolbar .ant-input-affix-wrapper {
  min-height: 38px;
}

.photoprism-app__toolbar-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 36px;
}

.photoprism-app__toolbar-left,
.photoprism-app__toolbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.photoprism-app__toolbar-left {
  min-width: 0;
}

.photoprism-app__toolbar-left--summary,
.photoprism-app__toolbar-left--actions {
  min-height: 40px;
}

.photoprism-app__toolbar-left--actions {
  gap: 8px;
  flex-wrap: nowrap;
}

.photoprism-app__toolbar-left span:not(.photoprism-app__mode-badge) {
  font-size: 12px;
  line-height: 1.2;
  white-space: nowrap;
}

.photoprism-app__mode-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  font-size: 11px;
  color: var(--photoprism-text-muted);
  background: rgba(255, 255, 255, 0.72);
}

.photoprism-app__selection-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 64px;
  min-height: 32px;
  padding: 0 10px;
  border-radius: 999px;
  opacity: 0;
  color: var(--photoprism-text-muted);
  background: rgba(255, 255, 255, 0.66);
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.16);
  transition:
    opacity 0.16s ease,
    color 0.16s ease,
    background-color 0.16s ease,
    box-shadow 0.16s ease;
}

.photoprism-app__selection-count--active {
  opacity: 1;
  color: var(--photoprism-accent-deep);
  background: rgba(var(--photoprism-accent-rgb), 0.12);
  box-shadow: inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.22);
}

.photoprism-app__toolbar-toggle.ant-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 34px;
  padding-inline: 11px;
  border-radius: 999px;
  color: var(--photoprism-text);
  background: rgba(255, 255, 255, 0.68);
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.18);
  white-space: nowrap;
}

.photoprism-app__toolbar-toggle--album.ant-btn {
  max-width: 42vw;
}

.photoprism-app__toolbar-toggle--album.ant-btn span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
}

.photoprism-app__toolbar-toggle--album-active.ant-btn:not(:disabled) {
  color: var(--photoprism-accent-deep);
  background: rgba(var(--photoprism-accent-rgb), 0.12);
  box-shadow: inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.2);
}

.photoprism-app__toolbar-toggle--filter.ant-btn {
  gap: 6px;
  padding-inline: 12px;
}

.photoprism-app__toolbar-toggle--filter-active.ant-btn:not(:disabled),
.photoprism-app__toolbar-toggle--filter-has-active.ant-btn:not(:disabled) {
  color: var(--photoprism-accent-deep);
  background: rgba(var(--photoprism-accent-rgb), 0.1);
  box-shadow:
    inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.24),
    0 10px 22px rgba(var(--photoprism-accent-rgb), 0.12);
}

.photoprism-app__toolbar-filter-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding-inline: 5px;
  border-radius: 999px;
  color: var(--photoprism-accent-contrast);
  background: linear-gradient(180deg, color-mix(in srgb, var(--photoprism-accent) 84%, white), var(--photoprism-accent-deep));
  box-shadow: 0 6px 16px rgba(var(--photoprism-accent-rgb), 0.22);
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
}

@media (max-width: 768px) {
  .photoprism-app__filter-sheet-mobile .photoprism-app__filter-group-heading {
    align-items: center;
  }

  .photoprism-app__filter-sheet-mobile .photoprism-app__filter-group-body--fields {
    gap: 8px;
  }

  .photoprism-app__filter-sheet-mobile .photoprism-app__filter-group-body--fields .ant-select-dropdown {
    max-height: min(42dvh, 320px);
  }

  .photoprism-app__toolbar-filter-badge {
    position: absolute;
    top: -3px;
    right: -2px;
    min-width: 16px;
    height: 16px;
    padding-inline: 4px;
    font-size: 9px;
  }
}

.photoprism-app__selection-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.photoprism-app__toolbar-toggle--select.ant-btn:not(:disabled) {
  color: var(--photoprism-accent-deep);
  background: rgba(var(--photoprism-accent-rgb), 0.12);
  box-shadow: inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.2);
}

.photoprism-app__toolbar-toggle--clear.ant-btn:not(:disabled) {
  color: #b91c1c;
  background: rgba(254, 242, 242, 0.94);
  box-shadow: inset 0 0 0 1px rgba(239, 68, 68, 0.18);
}

.photoprism-app__toolbar-toggle.ant-btn:disabled {
  color: rgba(100, 116, 139, 0.48);
  background: rgba(241, 245, 249, 0.72);
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.12);
}

.photoprism-app__toolbar-right .ant-segmented {
  padding: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.18);
}

.photoprism-app__toolbar-right .ant-segmented-item-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 26px;
  padding-inline: 9px;
  color: var(--photoprism-text);
  font-size: 12px;
}

.photoprism-app__content {
  position: relative;
  display: grid;
  min-height: 0;
  min-width: 0;
  padding: 0 8px 8px;
}

.photoprism-app__gallery {
  position: relative;
  min-height: 0;
  min-width: 0;
  overflow: auto;
  padding: 0;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.photoprism-app__pull-refresh {
  display: grid;
  place-items: end center;
  height: 0;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.76) 72%, rgba(255, 255, 255, 0));
  transition: height 0.2s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.photoprism-app__pull-refresh-indicator {
  --pull-refresh-progress: 0;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  margin: 0 auto 10px;
  border-radius: 50%;
  color: color-mix(in srgb, var(--photoprism-accent-deep) 58%, var(--photoprism-text-muted));
  background:
    radial-gradient(circle at 30% 28%, rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.72) 58%, rgba(255, 255, 255, 0.22) 100%);
  box-shadow:
    inset 0 0 0 1px rgba(148, 163, 184, 0.16),
    0 12px 24px rgba(15, 23, 42, 0.08);
  opacity: calc(0.4 + (var(--pull-refresh-progress) * 0.6));
  transform: translateY(calc((1 - var(--pull-refresh-progress)) * 8px)) scale(calc(0.88 + (var(--pull-refresh-progress) * 0.12)));
  transition:
    opacity 0.18s ease,
    transform 0.18s ease,
    box-shadow 0.18s ease,
    color 0.18s ease;
}

.photoprism-app__pull-refresh-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background:
    conic-gradient(
      from -90deg,
      rgba(var(--photoprism-accent-rgb), calc(0.14 + (var(--pull-refresh-progress) * 0.66))) 0deg,
      rgba(var(--photoprism-accent-rgb), calc(0.14 + (var(--pull-refresh-progress) * 0.66))) calc(var(--pull-refresh-progress) * 300deg),
      rgba(148, 163, 184, 0.18) calc(var(--pull-refresh-progress) * 300deg),
      rgba(148, 163, 184, 0.08) 360deg
    );
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 0);
  mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 0);
}

.photoprism-app__pull-refresh-icon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  line-height: 1;
}

.photoprism-app__pull-refresh-icon .ant-spin {
  line-height: 1;
}

.photoprism-app__pull-refresh--visible {
  box-shadow: inset 0 -1px 0 rgba(148, 163, 184, 0.12);
}

.photoprism-app__pull-refresh--armed .photoprism-app__pull-refresh-indicator {
  color: var(--photoprism-accent-deep);
  box-shadow:
    inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.18),
    0 16px 28px rgba(var(--photoprism-accent-rgb), 0.18);
}

.photoprism-app__gallery--selection-active {
  overflow: hidden;
  touch-action: none;
  -webkit-overflow-scrolling: auto;
}

.photoprism-app__gallery-refresh-blank {
  display: grid;
  place-items: center;
  min-height: min(42vh, 320px);
  padding: 32px 12px 48px;
}

.photoprism-app__gallery-refresh-blank .ant-spin {
  color: var(--photoprism-accent-deep);
}

.photoprism-app__gallery--list,
.photoprism-app__gallery--grid,
.photoprism-app__gallery--masonry {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.photoprism-app__gallery-section {
  display: grid;
  gap: 4px;
  align-content: start;
  contain: layout style paint;
  content-visibility: auto;
  contain-intrinsic-size: 960px;
}

.photoprism-app__gallery-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 54px;
  padding: 10px 12px;
  border: 1px solid rgba(var(--photoprism-accent-rgb), 0.12);
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(var(--photoprism-accent-rgb), 0.12), rgba(255, 255, 255, 0.9)),
    rgba(255, 255, 255, 0.88);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.46),
    0 10px 24px rgba(var(--photoprism-accent-rgb), 0.1);
}

.photoprism-app__gallery-section-toggle {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1 1 auto;
  min-width: 0;
  padding: 0;
  border: 0;
  color: inherit;
  background: transparent;
  text-align: left;
}

.photoprism-app__gallery-section-toggle-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  min-width: 30px;
  height: 30px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 999px;
  color: rgba(100, 116, 139, 0.92);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.42);
  font-size: 14px;
}

.photoprism-app__gallery-section-toggle-check--all {
  border-color: rgba(var(--photoprism-accent-rgb), 0.3);
  color: var(--photoprism-accent-contrast);
  background: linear-gradient(135deg, color-mix(in srgb, var(--photoprism-accent) 88%, white), var(--photoprism-accent-deep));
  box-shadow: 0 12px 22px rgba(var(--photoprism-accent-rgb), 0.24);
}

.photoprism-app__gallery-section-toggle-check--partial {
  border-color: rgba(var(--photoprism-accent-rgb), 0.24);
  color: var(--photoprism-accent-deep);
  background: rgba(var(--photoprism-accent-rgb), 0.12);
}

.photoprism-app__gallery-section-header--compact {
  min-height: 0;
  padding: 7px 2px 3px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.photoprism-app__gallery-section-heading {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.photoprism-app__gallery-section-heading strong {
  font-family: 'Georgia', 'Times New Roman', serif;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.15;
  color: var(--photoprism-accent-deep);
}

.photoprism-app__gallery-section-heading span {
  font-size: 11px;
  color: var(--photoprism-text-muted);
}

.photoprism-app__gallery-section-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.photoprism-app__gallery-section-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  color: var(--photoprism-accent-deep);
  background: rgba(var(--photoprism-accent-rgb), 0.12);
  box-shadow: inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.16);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.photoprism-app__gallery-section-action.is-active {
  background: linear-gradient(135deg, color-mix(in srgb, var(--photoprism-accent) 88%, white), var(--photoprism-accent-deep));
  color: var(--photoprism-accent-contrast);
  box-shadow: 0 10px 22px rgba(var(--photoprism-accent-rgb), 0.24);
}

.photoprism-app__gallery-section-action--clear {
  color: #b91c1c;
  background: rgba(254, 242, 242, 0.96);
  box-shadow: inset 0 0 0 1px rgba(239, 68, 68, 0.16);
}

.photoprism-app__gallery-section-action--clear.is-active {
  background: linear-gradient(135deg, rgba(248, 113, 113, 0.96), rgba(220, 38, 38, 0.92));
  color: #fff7f7;
  box-shadow: 0 10px 22px rgba(239, 68, 68, 0.22);
}

.photoprism-app__gallery-section-action:disabled {
  cursor: default;
  opacity: 0.56;
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.14);
}

.photoprism-app__gallery-section-body--grid {
  display: grid;
  gap: 8px;
  align-content: start;
}

.photoprism-app__gallery-section-body--grid.photoprism-app__gallery-section-body--density-compact {
  grid-template-columns: repeat(auto-fill, minmax(124px, 1fr));
}

.photoprism-app__gallery-section-body--grid.photoprism-app__gallery-section-body--density-comfortable {
  grid-template-columns: repeat(auto-fill, minmax(158px, 1fr));
}

.photoprism-app__gallery-section-body--grid.photoprism-app__gallery-section-body--density-large {
  grid-template-columns: repeat(auto-fill, minmax(198px, 1fr));
}

.photoprism-app__gallery-section-body--masonry {
  column-gap: 6px;
}

.photoprism-app__gallery-section-body--masonry.photoprism-app__gallery-section-body--density-compact {
  column-width: 124px;
}

.photoprism-app__gallery-section-body--masonry.photoprism-app__gallery-section-body--density-comfortable {
  column-width: 164px;
}

.photoprism-app__gallery-section-body--masonry.photoprism-app__gallery-section-body--density-large {
  column-width: 204px;
}

.photoprism-app__gallery-section-body--list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.photoprism-app__photo-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: inherit;
  background: transparent;
  cursor: pointer;
  min-width: 0;
  text-align: left;
  transition:
    transform 140ms ease,
    filter 140ms ease,
    box-shadow 140ms ease;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}

.photoprism-app__photo-card:hover,
.photoprism-app__photo-card:focus-visible {
  transform: translateY(-1px);
  filter: saturate(1.02);
}

.photoprism-app__photo-card--active {
  box-shadow: none;
}

.photoprism-app__photo-card--selected {
  background: transparent;
}

.photoprism-app__photo-card--selection-mode {
  box-shadow: none;
}

.photoprism-app__photo-card--range-target {
  box-shadow: none;
}

.photoprism-app__gallery--masonry .photoprism-app__photo-card {
  display: inline-grid;
  width: 100%;
  margin-bottom: 6px;
  break-inside: avoid;
}

.photoprism-app__gallery--list .photoprism-app__photo-card {
  grid-template-columns: 96px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 18px;
  background: var(--photoprism-surface);
  box-shadow: 0 14px 32px rgba(148, 163, 184, 0.12);
}

.photoprism-app__gallery--list .photoprism-app__photo-card:hover,
.photoprism-app__gallery--list .photoprism-app__photo-card:focus-visible {
  border-color: rgba(var(--photoprism-accent-rgb), 0.32);
  box-shadow: 0 18px 38px rgba(var(--photoprism-accent-rgb), 0.14);
}

.photoprism-app__gallery--list .photoprism-app__photo-card--active {
  border-color: rgba(var(--photoprism-accent-rgb), 0.48);
  box-shadow:
    inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.3),
    0 18px 40px rgba(var(--photoprism-accent-rgb), 0.12);
}

.photoprism-app__gallery--list .photoprism-app__photo-card--selected {
  background: linear-gradient(180deg, rgba(var(--photoprism-accent-rgb), 0.12), rgba(255, 255, 255, 0.88));
}

.photoprism-app__gallery--list .photoprism-app__photo-card--selection-mode,
.photoprism-app__gallery--list .photoprism-app__photo-card--range-target {
  box-shadow:
    inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.12),
    0 16px 34px rgba(var(--photoprism-accent-rgb), 0.1);
}

.photoprism-app__photo-card--grid,
.photoprism-app__photo-card--masonry {
  align-content: start;
}

.photoprism-app__gallery--list.photoprism-app__gallery--density-compact .photoprism-app__photo-card {
  grid-template-columns: 72px minmax(0, 1fr);
}

.photoprism-app__gallery--list.photoprism-app__gallery--density-large .photoprism-app__photo-card {
  grid-template-columns: 112px minmax(0, 1fr);
}

.photoprism-app__photo-thumb-shell {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 1 / 1;
  border-radius: 10px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(var(--photoprism-accent-rgb), 0.12), rgba(226, 232, 240, 0.72));
}

.photoprism-app__gallery--list .photoprism-app__photo-thumb-shell {
  width: 100%;
  height: auto;
  border-radius: 14px;
}

.photoprism-app__photo-thumb-shell::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 0 rgba(var(--photoprism-accent-rgb), 0);
  background-color: transparent;
  pointer-events: none;
  transition: box-shadow 140ms ease, background-color 140ms ease;
}

.photoprism-app__photo-card--active .photoprism-app__photo-thumb-shell::after {
  box-shadow: inset 0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.42);
}

.photoprism-app__photo-card--selected .photoprism-app__photo-thumb {
  filter: brightness(0.58) saturate(0.82);
}

.photoprism-app__photo-card--selected .photoprism-app__photo-thumb-shell::after,
.photoprism-app__photo-card--range-target .photoprism-app__photo-thumb-shell::after {
  box-shadow: inset 0 0 0 2px rgba(var(--photoprism-accent-rgb), 0.86);
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.18), rgba(15, 23, 42, 0.34)),
    rgba(var(--photoprism-accent-rgb), 0.08);
}

.photoprism-app__photo-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: filter 140ms ease;
}

.photoprism-app__photo-media-badge {
  position: absolute;
  left: 6px;
  right: 38px;
  bottom: 6px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  color: #fff7ed;
  background: rgba(15, 23, 42, 0.62);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.photoprism-app__photo-meta {
  display: grid;
  gap: 2px;
  min-width: 0;
  text-align: left;
}

.photoprism-app__photo-meta strong {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  font-size: 12px;
  line-height: 1.25;
  color: var(--photoprism-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.photoprism-app__photo-meta span {
  font-size: 11px;
  line-height: 1.2;
  color: var(--photoprism-text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.photoprism-app__photo-mode-copy {
  color: var(--photoprism-accent-deep);
}

.photoprism-app__photo-favorite-chip {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 0 8px;
  border-radius: 999px;
  color: #be185d;
  background: rgba(255, 241, 242, 0.94);
  box-shadow: inset 0 0 0 1px rgba(244, 63, 94, 0.18);
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: visible;
  text-overflow: clip;
}

.photoprism-app__photo-overlay-action {
  position: absolute;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 26px;
  min-width: 26px;
  height: 26px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.14);
  backdrop-filter: blur(8px);
  color: rgba(255, 255, 255, 0.96);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.22),
    0 3px 8px rgba(15, 23, 42, 0.08);
  touch-action: manipulation;
  opacity: 0.72;
}

.photoprism-app__photo-detail {
  top: 5px;
  right: 5px;
  font-size: 12px;
}

.photoprism-app__photo-favorite {
  top: 5px;
  left: 5px;
  font-size: 12px;
}

.photoprism-app__photo-favorite--active {
  border-color: rgba(255, 255, 255, 0.88);
  color: #fff1f2;
  background: linear-gradient(180deg, rgba(251, 113, 133, 0.98), rgba(225, 29, 72, 0.96));
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.22),
    0 12px 24px rgba(225, 29, 72, 0.3);
  opacity: 1;
}

.photoprism-app__photo-favorite:disabled {
  opacity: 0.68;
}

.photoprism-app__photo-check {
  right: 5px;
  bottom: 5px;
  border-color: rgba(255, 255, 255, 0.82);
  color: rgba(255, 255, 255, 0.98);
  background: rgba(15, 23, 42, 0.38);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.28),
    0 8px 18px rgba(15, 23, 42, 0.18);
}

.photoprism-app__photo-check--selected {
  border-color: rgba(255, 255, 255, 0.92);
  color: var(--photoprism-accent-contrast);
  background: linear-gradient(180deg, color-mix(in srgb, var(--photoprism-accent) 88%, white), var(--photoprism-accent-deep));
  box-shadow:
    0 12px 24px rgba(var(--photoprism-accent-rgb), 0.24),
    inset 0 0 0 1px rgba(255, 255, 255, 0.24);
}

.photoprism-app__loading,
.photoprism-app__empty {
  display: grid;
  place-items: center;
  min-height: 0;
}

.photoprism-app__loading-overlay {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.84);
  backdrop-filter: blur(10px);
}

.photoprism-app__gallery-load-more {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  padding: 8px 12px 18px;
  color: var(--photoprism-text-muted);
  font-size: 12px;
  line-height: 1.4;
  text-align: center;
}

.photoprism-app__gallery-load-more .ant-spin {
  flex: 0 0 auto;
}

.photoprism-app__mobile-utility-sheet {
  display: none;
}

.photoprism-app__photo-card--placeholder {
  pointer-events: none;
}

.photoprism-app__photo-meta--placeholder {
  gap: 6px;
}

.photoprism-app__photo-thumb-skeleton,
.photoprism-app__photo-line-skeleton {
  display: block;
  width: 100%;
  border-radius: 999px;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0.44) 50%, rgba(255, 255, 255, 0.12) 100%),
    linear-gradient(180deg, rgba(226, 232, 240, 0.92), rgba(241, 245, 249, 0.92));
  background-size: 240px 100%, 100% 100%;
  animation: photoprism-skeleton-shimmer 1.2s linear infinite;
}

.photoprism-app__photo-thumb-skeleton {
  width: 100%;
  height: 100%;
  border-radius: inherit;
}

.photoprism-app__photo-line-skeleton {
  height: 10px;
}

.photoprism-app__photo-line-skeleton--title {
  width: 78%;
}

.photoprism-app__gallery--grid .photoprism-app__photo-meta,
.photoprism-app__gallery--grid .photoprism-app__photo-meta--placeholder,
.photoprism-app__gallery--masonry .photoprism-app__photo-meta,
.photoprism-app__gallery--masonry .photoprism-app__photo-meta--placeholder {
  display: none;
}

@keyframes photoprism-skeleton-shimmer {
  0% {
    background-position: -240px 0, 0 0;
  }

  100% {
    background-position: 240px 0, 0 0;
  }
}

.photoprism-app__viewer-modal .ant-modal-content,
.photoprism-app__viewer-modal .fullscreen-preview-modal__shell,
.photoprism-app__viewer-modal .fullscreen-preview-modal__content {
  color: var(--photoprism-viewer-text);
  background-color: var(--photoprism-viewer-shell-bottom);
  background-image: linear-gradient(
    180deg,
    var(--photoprism-viewer-shell-top) 0%,
    var(--photoprism-viewer-shell-mid) 48%,
    var(--photoprism-viewer-shell-bottom) 100%
  );
  background-repeat: no-repeat;
}

.photoprism-app__viewer-modal .fullscreen-preview-modal__header {
  border-bottom: 1px solid var(--photoprism-viewer-line);
  background: linear-gradient(
    180deg,
    var(--photoprism-viewer-surface) 0%,
    var(--photoprism-viewer-surface-strong) 100%
  );
  box-shadow:
    inset 0 -1px 0 rgba(var(--photoprism-viewer-shadow-rgb), 0.06),
    0 18px 40px rgba(var(--photoprism-viewer-shadow-rgb), 0.18);
  backdrop-filter: none;
}

.photoprism-app__viewer-modal .fullscreen-preview-modal__title,
.photoprism-app__viewer-modal .fullscreen-preview-modal__meta {
  color: var(--photoprism-viewer-text);
}

.photoprism-app__viewer-modal .fullscreen-preview-modal__meta {
  color: var(--photoprism-viewer-text-muted);
}

.photoprism-app__viewer-modal .fullscreen-preview-modal__icon-button.ant-btn {
  color: var(--photoprism-viewer-control-text);
  background: linear-gradient(
    135deg,
    var(--photoprism-viewer-control-surface) 0%,
    var(--photoprism-viewer-surface-strong) 100%
  );
  box-shadow:
    0 14px 28px rgba(var(--photoprism-viewer-shadow-rgb), 0.16),
    inset 0 0 0 1px var(--photoprism-viewer-line);
}

.photoprism-app__viewer-modal .fullscreen-preview-modal__icon-button.ant-btn:hover,
.photoprism-app__viewer-modal .fullscreen-preview-modal__icon-button.ant-btn:focus,
.photoprism-app__viewer-modal .fullscreen-preview-modal__icon-button.ant-btn:focus-visible,
.photoprism-app__viewer-modal .fullscreen-preview-modal__icon-button.ant-btn:active,
.photoprism-app__viewer-modal .fullscreen-preview-modal__icon-button.ant-btn.ant-btn-text:not(:disabled):not(.ant-btn-disabled):active {
  color: var(--photoprism-viewer-control-text);
  background: linear-gradient(
    135deg,
    var(--photoprism-viewer-control-surface-hover) 0%,
    var(--photoprism-viewer-control-surface-active) 100%
  );
  box-shadow:
    0 16px 30px rgba(var(--photoprism-viewer-shadow-rgb), 0.18),
    inset 0 0 0 1px var(--photoprism-viewer-line-strong);
}

.photoprism-app__viewer-modal .fullscreen-preview-modal__icon-button.ant-btn .ant-btn-icon,
.photoprism-app__viewer-modal .fullscreen-preview-modal__icon-button.ant-btn .anticon,
.photoprism-app__viewer-modal .fullscreen-preview-modal__icon-button.ant-btn .anticon svg {
  color: inherit;
  fill: currentColor;
}

.photoprism-app__viewer-shell {
  position: relative;
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  isolation: isolate;
  color: var(--photoprism-viewer-text);
  background-color: var(--photoprism-viewer-shell-bottom);
  background-image: linear-gradient(
    180deg,
    var(--photoprism-viewer-shell-top) 0%,
    var(--photoprism-viewer-shell-mid) 54%,
    var(--photoprism-viewer-shell-bottom) 100%
  );
  background-repeat: no-repeat;
}

.photoprism-app__viewer-topbar {
  position: relative;
  z-index: 5;
  display: grid;
  gap: 10px;
  padding: 14px 18px 12px;
  border-bottom: 1px solid var(--photoprism-viewer-line);
  background: linear-gradient(
    180deg,
    var(--photoprism-viewer-surface) 0%,
    var(--photoprism-viewer-surface-strong) 100%
  );
}

.photoprism-app__viewer-tabbar {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--photoprism-viewer-text-muted);
}

.photoprism-app__viewer-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  min-height: 38px;
  padding: 0 16px;
  border: 1px solid var(--photoprism-viewer-line);
  border-radius: 999px;
  color: var(--photoprism-viewer-control-text);
  background-color: var(--photoprism-viewer-control-surface);
  box-shadow:
    0 10px 24px rgba(var(--photoprism-viewer-shadow-rgb), 0.12),
    inset 0 0 0 1px var(--photoprism-viewer-line);
  font-size: 13px;
  font-weight: 600;
  transition:
    color 140ms ease,
    background-color 140ms ease,
    border-color 140ms ease,
    box-shadow 140ms ease,
    transform 140ms ease;
}

.photoprism-app__viewer-tab:hover,
.photoprism-app__viewer-tab:focus-visible {
  border-color: var(--photoprism-viewer-line-strong);
  color: var(--photoprism-viewer-control-text);
  background-color: var(--photoprism-viewer-control-surface-hover);
  transform: translateY(-1px);
}

.photoprism-app__viewer-tab--active {
  border-color: var(--photoprism-viewer-line-strong);
  color: var(--photoprism-viewer-control-text);
  background: linear-gradient(135deg, var(--photoprism-viewer-accent), var(--photoprism-viewer-accent-deep));
  box-shadow:
    0 18px 36px rgba(var(--photoprism-viewer-shadow-rgb), 0.18),
    inset 0 0 0 1px rgba(255, 255, 255, 0.32);
}

.photoprism-app__viewer-toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.photoprism-app__viewer-settings-trigger.ant-btn {
  position: relative;
}

.photoprism-app__viewer-settings-trigger--active.ant-btn,
.photoprism-app__viewer-settings-trigger.ant-btn:hover,
.photoprism-app__viewer-settings-trigger.ant-btn:focus-visible {
  color: var(--photoprism-viewer-control-text);
  background: var(--photoprism-viewer-control-surface-hover);
  box-shadow:
    0 14px 28px rgba(var(--photoprism-viewer-shadow-rgb), 0.14),
    inset 0 0 0 1px var(--photoprism-viewer-line-strong);
}

.photoprism-app__viewer-theme-menu {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  width: min(420px, calc(100vw - 24px));
  max-height: min(72dvh, 560px);
  padding: 12px;
  overflow: auto;
  border: 1px solid var(--photoprism-viewer-line);
  border-radius: 22px;
  background:
    linear-gradient(180deg, var(--photoprism-viewer-surface) 0%, var(--photoprism-viewer-surface-strong) 100%);
  box-shadow:
    0 24px 48px rgba(var(--photoprism-viewer-shadow-rgb), 0.22),
    inset 0 0 0 1px rgba(255, 255, 255, 0.26);
}

.photoprism-app__viewer-theme-menu-item {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 68px;
  padding: 10px 12px;
  border: 1px solid var(--photoprism-viewer-line);
  border-radius: 18px;
  color: var(--photoprism-viewer-control-text);
  background: linear-gradient(
    180deg,
    var(--photoprism-viewer-control-surface) 0%,
    var(--photoprism-viewer-surface-strong) 100%
  );
  text-align: left;
  box-shadow:
    0 12px 24px rgba(var(--photoprism-viewer-shadow-rgb), 0.1),
    inset 0 0 0 1px rgba(255, 255, 255, 0.28);
  transition:
    border-color 140ms ease,
    box-shadow 140ms ease,
    transform 140ms ease,
    background-color 140ms ease;
}

.photoprism-app__viewer-theme-menu-item:hover,
.photoprism-app__viewer-theme-menu-item:focus-visible {
  border-color: var(--photoprism-viewer-line-strong);
  background: linear-gradient(
    180deg,
    var(--photoprism-viewer-control-surface-hover) 0%,
    var(--photoprism-viewer-control-surface-active) 100%
  );
  transform: translateY(-1px);
}

.photoprism-app__viewer-theme-menu-item--active {
  border-color: var(--photoprism-viewer-line-strong);
  background: linear-gradient(135deg, var(--photoprism-viewer-accent), var(--photoprism-viewer-accent-deep));
  box-shadow:
    0 16px 32px rgba(var(--photoprism-viewer-shadow-rgb), 0.16),
    inset 0 0 0 1px rgba(255, 255, 255, 0.36);
}

.photoprism-app__viewer-theme-menu-item--active .photoprism-app__viewer-theme-menu-copy span,
.photoprism-app__viewer-theme-menu-item--active .photoprism-app__viewer-theme-menu-check {
  color: var(--photoprism-viewer-control-text);
}

.photoprism-app__viewer-theme-menu-swatch {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.48),
    0 10px 18px rgba(var(--photoprism-viewer-shadow-rgb), 0.18);
}

.photoprism-app__viewer-theme-menu-copy {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.photoprism-app__viewer-theme-menu-copy strong {
  font-size: 13px;
}

.photoprism-app__viewer-theme-menu-copy span {
  font-size: 11px;
  line-height: 1.4;
  color: var(--photoprism-viewer-text-muted);
}

.photoprism-app__viewer-theme-menu-check {
  font-size: 16px;
  color: var(--photoprism-viewer-text-muted);
}

.photoprism-app__viewer-tab-summary {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
  margin-left: auto;
  color: var(--photoprism-viewer-text-muted);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  text-align: right;
}

.photoprism-app__viewer-tab-summary-item {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid var(--photoprism-viewer-line);
  border-radius: 999px;
  color: var(--photoprism-viewer-control-text);
  background-color: var(--photoprism-viewer-surface);
  box-shadow:
    0 10px 24px rgba(var(--photoprism-viewer-shadow-rgb), 0.1),
    inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.photoprism-app__viewer-tab-summary-item--primary {
  border-color: var(--photoprism-viewer-line-strong);
  color: var(--photoprism-viewer-control-text);
  background-image: linear-gradient(135deg, var(--photoprism-viewer-accent), var(--photoprism-viewer-accent-deep));
}

.photoprism-app__viewer-stage {
  position: relative;
  display: flex;
  flex: 1 1 auto;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  background-color: var(--photoprism-viewer-stage-bottom);
  background-image: linear-gradient(
    180deg,
    var(--photoprism-viewer-stage-top) 0%,
    var(--photoprism-viewer-stage-bottom) 100%
  );
}

.photoprism-app__viewer-stage--video {
  display: grid;
}

.photoprism-app__viewer-stage--placeholder,
.photoprism-app__viewer-video-frame--placeholder {
  background-color: var(--photoprism-viewer-stage-bottom);
  background-image:
    linear-gradient(180deg, var(--photoprism-viewer-stage-top), var(--photoprism-viewer-stage-bottom)),
    var(--photoprism-viewer-placeholder-image) center / cover no-repeat;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.photoprism-app__viewer-main {
  position: relative;
  display: flex;
  flex: 1 1 auto;
  min-width: 0;
  min-height: 0;
  z-index: 1;
}

.photoprism-app__viewer-nav.ant-btn {
  position: absolute;
  top: 50%;
  z-index: 4;
  width: 48px;
  min-width: 48px;
  height: 48px;
  padding: 0;
  border-radius: 999px;
  color: var(--photoprism-viewer-control-text);
  background: linear-gradient(
    135deg,
    var(--photoprism-viewer-control-surface) 0%,
    var(--photoprism-viewer-surface-strong) 100%
  );
  box-shadow:
    0 18px 38px rgba(var(--photoprism-viewer-shadow-rgb), 0.18),
    inset 0 0 0 1px var(--photoprism-viewer-line);
  transform: translateY(-50%);
  transition:
    color 140ms ease,
    background-color 140ms ease,
    box-shadow 140ms ease,
    transform 140ms ease;
}

.photoprism-app__viewer-nav.ant-btn:hover,
.photoprism-app__viewer-nav.ant-btn:focus-visible {
  color: var(--photoprism-viewer-control-text);
  background: linear-gradient(
    135deg,
    var(--photoprism-viewer-control-surface-hover) 0%,
    var(--photoprism-viewer-control-surface-active) 100%
  );
  box-shadow:
    0 22px 42px rgba(var(--photoprism-viewer-shadow-rgb), 0.2),
    inset 0 0 0 1px var(--photoprism-viewer-line-strong);
  transform: translateY(calc(-50% - 1px));
}

.photoprism-app__viewer-nav.ant-btn[disabled] {
  color: color-mix(in srgb, var(--photoprism-viewer-control-text) 38%, white);
  background: var(--photoprism-viewer-surface-soft);
  box-shadow: inset 0 0 0 1px var(--photoprism-viewer-line);
}

.photoprism-app__viewer-nav--previous {
  left: 18px;
}

.photoprism-app__viewer-nav--next {
  right: 18px;
}

.photoprism-app__viewer-stage-sidecar {
  position: absolute;
  top: 20px;
  right: 18px;
  z-index: 4;
  display: grid;
  justify-items: end;
  gap: 12px;
  pointer-events: none;
}

.photoprism-app__viewer-stage-actions {
  display: grid;
  gap: 8px;
  pointer-events: auto;
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.photoprism-app__viewer-stage-actions--hidden {
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
}

.photoprism-app__viewer-stage-action.ant-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: auto;
  min-width: 120px;
  height: 42px;
  padding: 0 14px;
  border-radius: 16px;
  color: var(--photoprism-viewer-control-text);
  background: linear-gradient(
    135deg,
    var(--photoprism-viewer-control-surface) 0%,
    var(--photoprism-viewer-surface-strong) 100%
  );
  box-shadow:
    0 18px 40px rgba(var(--photoprism-viewer-shadow-rgb), 0.18),
    inset 0 0 0 1px var(--photoprism-viewer-line);
  transition:
    color 140ms ease,
    background-color 140ms ease,
    box-shadow 140ms ease,
    transform 140ms ease;
}

.photoprism-app__viewer-stage-action.ant-btn:hover,
.photoprism-app__viewer-stage-action.ant-btn:focus-visible {
  color: var(--photoprism-viewer-control-text);
  background: linear-gradient(
    135deg,
    var(--photoprism-viewer-control-surface-hover) 0%,
    var(--photoprism-viewer-control-surface-active) 100%
  );
  box-shadow:
    0 18px 40px rgba(var(--photoprism-viewer-shadow-rgb), 0.2),
    inset 0 0 0 1px var(--photoprism-viewer-line-strong);
  transform: translateY(-1px);
}

.photoprism-app__viewer-stage-action--selected.ant-btn {
  color: var(--photoprism-accent-contrast);
  background: linear-gradient(135deg, var(--photoprism-viewer-accent), var(--photoprism-viewer-accent-deep));
  box-shadow:
    0 18px 40px rgba(var(--photoprism-accent-rgb), 0.28),
    inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.photoprism-app__viewer-stage-action--favorite.ant-btn {
  color: #ffe4e6;
}

.photoprism-app__viewer-stage-action.ant-btn[disabled] {
  color: color-mix(in srgb, var(--photoprism-viewer-control-text) 38%, white);
  background: var(--photoprism-viewer-surface-soft);
}

.photoprism-app__zoom-surface {
  flex: 1 1 auto;
}

.photoprism-app__zoom-stage {
  padding: 72px 84px 152px;
  background-color: var(--photoprism-viewer-stage-bottom);
}

.photoprism-app__viewer-modal .zoomable-preview-surface__toolbar {
  background: linear-gradient(
    135deg,
    var(--photoprism-viewer-control-surface) 0%,
    var(--photoprism-viewer-surface-strong) 100%
  );
  box-shadow:
    0 14px 28px rgba(var(--photoprism-viewer-shadow-rgb), 0.16),
    inset 0 0 0 1px var(--photoprism-viewer-line);
}

.photoprism-app__viewer-modal .zoomable-preview-surface__value.ant-typography {
  color: var(--photoprism-viewer-text);
}

.photoprism-app__zoom-content {
  display: grid;
  place-items: center;
  min-width: 100%;
  min-height: 100%;
}

.photoprism-app__viewer-image {
  max-width: 100%;
  max-height: calc(100dvh - 168px);
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 22px;
  box-shadow:
    0 32px 80px rgba(2, 6, 23, 0.42),
    0 0 0 1px rgba(255, 255, 255, 0.08);
  background-color: var(--photoprism-viewer-media-surface);
}

.photoprism-app__viewer-video-frame {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  min-height: 100%;
  padding: 72px 84px 152px;
  background-color: var(--photoprism-viewer-stage-bottom);
}

.photoprism-app__viewer-video {
  width: min(100%, 1080px);
  max-height: calc(100dvh - 168px);
  border-radius: 22px;
  background-color: var(--photoprism-viewer-media-surface);
  box-shadow:
    0 32px 80px rgba(2, 6, 23, 0.42),
    0 0 0 1px rgba(255, 255, 255, 0.08);
}

.photoprism-app__viewer-video-status {
  display: grid;
  gap: 10px;
  width: min(100%, 720px);
  padding: 14px 16px;
  border-radius: 16px;
  color: #ffe4e6;
  background: rgba(41, 10, 18, 0.84);
  box-shadow:
    0 18px 40px rgba(15, 23, 42, 0.26),
    inset 0 0 0 1px rgba(248, 113, 113, 0.3);
  font-size: 13px;
  line-height: 1.5;
  text-align: left;
}

.photoprism-app__viewer-video-status strong {
  font-size: 14px;
}

.photoprism-app__viewer-video-status span {
  color: rgba(254, 226, 226, 0.92);
}

.photoprism-app__viewer-video-status--loading {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  width: auto;
  min-width: 56px;
  min-height: 56px;
  padding: 12px;
  color: var(--photoprism-viewer-control-text);
  background: var(--photoprism-viewer-surface-strong);
  box-shadow:
    0 18px 40px rgba(var(--photoprism-viewer-shadow-rgb), 0.2),
    inset 0 0 0 1px var(--photoprism-viewer-line);
}

.photoprism-app__viewer-video-status--error {
  max-width: min(100%, 720px);
}

.photoprism-app__viewer-video-status--inline {
  margin-top: 2px;
  background: rgba(127, 29, 29, 0.46);
}

.photoprism-app__viewer-video-status-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.photoprism-app__viewer-video-status-actions .ant-btn {
  min-height: 34px;
  pointer-events: auto;
}

.photoprism-app__viewer-rail {
  position: absolute;
  bottom: 18px;
  left: 50%;
  z-index: 4;
  display: flex;
  gap: 10px;
  width: min(100%, 760px);
  max-width: calc(100vw - 32px);
  padding: 12px;
  overflow-x: auto;
  border-radius: 24px;
  background-color: var(--photoprism-viewer-rail-surface);
  box-shadow:
    0 20px 44px rgba(var(--photoprism-viewer-shadow-rgb), 0.22),
    inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  transform: translateX(-50%);
  scrollbar-width: thin;
  overscroll-behavior-x: contain;
  touch-action: pan-x;
}

.photoprism-app__viewer-rail-item {
  position: relative;
  display: inline-flex;
  flex: 0 0 auto;
  width: 64px;
  height: 64px;
  padding: 0;
  overflow: hidden;
  border: 2px solid var(--photoprism-viewer-line);
  border-radius: 18px;
  background: var(--photoprism-viewer-surface);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
  transition:
    border-color 140ms ease,
    box-shadow 140ms ease,
    transform 140ms ease,
    filter 140ms ease;
}

.photoprism-app__viewer-rail-item:hover,
.photoprism-app__viewer-rail-item:focus-visible {
  border-color: rgba(255, 255, 255, 0.26);
  box-shadow:
    0 10px 24px rgba(2, 6, 23, 0.28),
    inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  transform: translateY(-1px);
}

.photoprism-app__viewer-rail-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photoprism-app__viewer-rail-media-badge {
  position: absolute;
  right: 6px;
  bottom: 6px;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  color: var(--photoprism-viewer-control-text);
  background: var(--photoprism-viewer-control-surface);
  box-shadow:
    0 6px 14px rgba(2, 6, 23, 0.28),
    inset 0 0 0 1px rgba(255, 255, 255, 0.14);
  font-size: 12px;
}

.photoprism-app__viewer-rail-item--active {
  border-color: var(--photoprism-viewer-accent);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.16),
    0 0 0 4px rgba(var(--photoprism-accent-rgb), 0.22),
    0 12px 28px rgba(var(--photoprism-accent-rgb), 0.2);
}

.photoprism-app__viewer-info-page {
  display: grid;
  flex: 1 1 auto;
  align-content: start;
  gap: 12px;
  width: min(980px, calc(100vw - 36px));
  margin: 0 auto;
  padding: 12px 0 124px;
  overflow: auto;
  color: var(--photoprism-viewer-text);
}

.photoprism-app__viewer-info-hero {
  display: grid;
  place-items: center;
  min-height: 156px;
  padding: 0;
  overflow: hidden;
  border-radius: 18px;
  background-color: #0c1524;
  background-image:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(15, 23, 42, 0.12)),
    #0c1524;
  box-shadow:
    0 20px 44px rgba(2, 6, 23, 0.22),
    inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.photoprism-app__viewer-info-hero img {
  display: block;
  width: 100%;
  max-height: 220px;
  object-fit: cover;
}

.photoprism-app__viewer-info-hero--video video {
  display: block;
  width: 100%;
  max-height: 320px;
  background-color: #020617;
}

.photoprism-app__viewer-info-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.photoprism-app__viewer-info-actions .ant-btn {
  min-height: 42px;
  border-radius: 14px;
  color: var(--photoprism-viewer-control-text);
  border-color: var(--photoprism-viewer-line);
  background-color: var(--photoprism-viewer-control-surface);
  box-shadow:
    0 14px 30px rgba(var(--photoprism-viewer-shadow-rgb), 0.14),
    inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.photoprism-app__viewer-info-actions .ant-btn:hover,
.photoprism-app__viewer-info-actions .ant-btn:focus-visible {
  color: var(--photoprism-viewer-control-text);
  border-color: var(--photoprism-viewer-line-strong);
  background: var(--photoprism-viewer-control-surface-hover);
}

.photoprism-app__viewer-album-panel {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--photoprism-viewer-line);
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(var(--photoprism-viewer-shadow-rgb), 0.1), transparent 58%),
    var(--photoprism-viewer-control-surface);
  box-shadow:
    0 16px 34px rgba(var(--photoprism-viewer-shadow-rgb), 0.12),
    inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.photoprism-app__viewer-album-panel-head {
  display: grid;
  gap: 4px;
}

.photoprism-app__viewer-album-panel-head strong {
  font-size: 14px;
  color: var(--photoprism-viewer-text);
}

.photoprism-app__viewer-album-panel-head span,
.photoprism-app__viewer-album-empty {
  font-size: 12px;
  color: var(--photoprism-viewer-text-subtle);
}

.photoprism-app__viewer-album-panel-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: stretch;
}

.photoprism-app__viewer-album-select,
.photoprism-app__viewer-album-select .ant-select-selector {
  min-height: 42px;
}

.photoprism-app__viewer-album-panel-actions .ant-btn {
  min-height: 42px;
  border-radius: 14px;
  color: var(--photoprism-viewer-control-text);
  border-color: var(--photoprism-viewer-line);
  background-color: var(--photoprism-viewer-control-surface);
}

.photoprism-app__viewer-album-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.photoprism-app__viewer-album-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid var(--photoprism-viewer-line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--photoprism-viewer-text);
  transition:
    border-color 0.2s ease,
    background-color 0.2s ease,
    transform 0.2s ease;
}

.photoprism-app__viewer-album-chip:hover,
.photoprism-app__viewer-album-chip:focus-visible {
  border-color: var(--photoprism-viewer-line-strong);
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-1px);
}

.photoprism-app__viewer-album-chip:disabled {
  opacity: 0.64;
  cursor: not-allowed;
  transform: none;
}

.photoprism-app__viewer-panel-head {
  display: grid;
  gap: 4px;
  padding: 0;
  color: var(--photoprism-viewer-text);
}

.photoprism-app__viewer-panel-head strong {
  font-family: 'Georgia', 'Times New Roman', serif;
  font-size: 18px;
}

.photoprism-app__viewer-panel-head span {
  color: var(--photoprism-viewer-text-subtle);
  font-size: 12px;
}

.photoprism-app__viewer-panel-loading {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 2px;
  color: var(--photoprism-viewer-text-subtle);
  font-size: 12px;
}

.photoprism-app__viewer-details {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--photoprism-viewer-line);
}

.photoprism-app__viewer-detail-row {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--photoprism-viewer-line);
}

.photoprism-app__viewer-detail-row.is-muted dd {
  color: var(--photoprism-viewer-text-muted);
  font-size: 13px;
}

.photoprism-app__viewer-details dt {
  margin: 0;
  color: var(--photoprism-viewer-text-subtle);
  font-size: 12px;
}

.photoprism-app__viewer-details dd {
  margin: 0;
  color: var(--photoprism-viewer-text);
  font-size: 13px;
  line-height: 1.5;
  word-break: break-word;
  text-align: left;
}

@media (max-width: 1024px) {
  .photoprism-app__workspace {
    grid-template-columns: 220px minmax(0, 1fr);
  }
}

@media (max-width: 768px) {
  .photoprism-app::before {
    display: none;
  }

  .photoprism-app__topbar {
    padding: 6px 8px;
    background: rgba(255, 250, 245, 0.98);
  }

  .photoprism-app__brand strong {
    font-size: 15px;
  }

  .photoprism-app__brand span {
    display: none;
  }

  .photoprism-app__brand {
    gap: 6px;
  }

  .photoprism-app__brand .ant-btn,
  .photoprism-app__actions .ant-btn {
    width: 34px;
    min-width: 34px;
    height: 34px;
    padding: 0;
  }

  .photoprism-app__back-button.ant-btn {
    width: 36px;
    min-width: 36px;
    height: 36px;
  }

  .photoprism-app__workspace {
    grid-template-columns: minmax(0, 1fr);
    position: relative;
  }

  .photoprism-app__sidebar {
    grid-template-rows: minmax(0, 1fr);
    padding: 10px;
    border-right: 0;
    background: color-mix(in srgb, var(--photoprism-panel-strong) 96%, white);
  }

  .photoprism-app__sidebar--sheet {
    position: absolute;
    top: 4px;
    right: 8px;
    left: 8px;
    z-index: 4;
    grid-template-rows: auto minmax(0, 1fr);
    max-height: min(calc(100dvh - 24px), 760px);
    overflow: hidden;
    border: 1px solid rgba(var(--photoprism-accent-rgb), 0.16);
    border-radius: 24px;
    box-shadow:
      0 24px 48px rgba(15, 23, 42, 0.16),
      0 0 0 1px rgba(var(--photoprism-accent-rgb), 0.08);
    backdrop-filter: blur(22px);
  }

  .photoprism-app__sidebar-sheet-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
    padding: 6px 4px 0;
  }

  .photoprism-app__sidebar-sheet-copy {
    display: grid;
    gap: 2px;
    min-width: 0;
  }

  .photoprism-app__sidebar-sheet-copy strong {
    font-size: 15px;
    color: var(--photoprism-accent-deep);
  }

  .photoprism-app__sidebar-sheet-copy span {
    font-size: 12px;
    color: var(--photoprism-text-muted);
  }

  .photoprism-app__sidebar-sheet-actions {
    display: inline-flex;
    align-items: center;
    gap: 6px;
  }

  .photoprism-app__sidebar-sheet-actions .ant-btn {
    color: var(--photoprism-accent-deep);
  }

  .photoprism-app__album-list {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(108px, 1fr);
    overflow-x: auto;
    overflow-y: hidden;
    gap: 6px;
  }

  .photoprism-app__album-item {
    min-height: 38px;
    justify-content: center;
    padding: 0 10px;
    border-radius: 14px;
    color: var(--photoprism-text);
    background: color-mix(in srgb, var(--photoprism-panel-soft) 94%, white);
  }

  .photoprism-app__theme-preview-card {
    align-items: flex-start;
  }

  .photoprism-app__filter-group-body--theme > .photoprism-app__theme-preview-card {
    margin-bottom: 10px;
    white-space: normal;
  }

  .photoprism-app__filter-group-body--theme > .photoprism-app__theme-chip {
    display: inline-grid;
    width: 148px;
    margin-right: 8px;
    vertical-align: top;
    white-space: normal;
    scroll-snap-align: start;
  }

  .photoprism-app__filter-group-body--theme {
    display: block;
    padding-bottom: 4px;
    scrollbar-width: none;
    white-space: nowrap;
    overflow-x: auto;
    overflow-y: visible;
  }

  .photoprism-app__filter-group-body--theme::-webkit-scrollbar {
    display: none;
  }

  .photoprism-app__toolbar {
    gap: 4px;
    padding: 6px 6px 4px;
  }

  .photoprism-app__toolbar-search {
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 4px;
  }

  .photoprism-app__search--toolbar .ant-input-affix-wrapper {
    min-height: 36px;
    border-radius: 18px;
    padding-inline: 10px;
  }

  .photoprism-app__toolbar-toggle--album.ant-btn {
    max-width: none;
    width: auto;
    min-width: 34px;
    height: 34px;
    padding-inline: 10px;
  }

  .photoprism-app__toolbar-toggle--filter.ant-btn {
    position: relative;
    justify-content: center;
    min-width: 36px;
    width: 36px;
    height: 36px;
    gap: 0;
    padding-inline: 0;
    border-radius: 18px;
  }

  .photoprism-app__toolbar-toggle--filter.ant-btn .anticon {
    font-size: 15px;
  }

  .photoprism-app__toolbar-preview-switch .ant-segmented {
    max-width: 124px;
  }

  .photoprism-app__toolbar-preview-switch .ant-segmented-item-label {
    min-width: 26px;
    min-height: 26px;
    padding-inline: 6px;
  }

  .photoprism-app__toolbar-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 6px;
    min-height: 34px;
  }

  .photoprism-app__toolbar-left {
    gap: 6px;
    min-width: 0;
  }

  .photoprism-app__toolbar-right {
    justify-content: flex-end;
    min-width: 0;
  }

  .photoprism-app__toolbar-left--actions {
    overflow: hidden;
  }

  .photoprism-app__toolbar-right .ant-btn {
    min-height: 34px;
  }

  .photoprism-app__toolbar-right .ant-segmented {
    max-width: 100%;
  }

  .photoprism-app__toolbar-right .ant-segmented-item-label {
    min-height: 24px;
    padding-inline: 7px;
    font-size: 11px;
    gap: 4px;
  }

  .photoprism-app__toolbar-right--preview .ant-segmented-item-label .anticon {
    font-size: 13px;
  }

  .photoprism-app__selection-count {
    min-width: 56px;
    min-height: 30px;
    padding-inline: 9px;
    flex: 0 0 auto;
    font-size: 11px;
  }

  .photoprism-app__toolbar-toggle.ant-btn {
    min-width: 0;
    min-height: 32px;
    padding-inline: 8px;
    font-size: 11px;
    flex: 0 1 auto;
  }

  .photoprism-app__selection-actions {
    gap: 6px;
    min-width: 0;
    flex: 1 1 auto;
  }

  .photoprism-app__toolbar-toggle.ant-btn .anticon + span,
  .photoprism-app__toolbar-toggle.ant-btn span + .anticon {
    min-width: 0;
  }

  .photoprism-app__content {
    padding: 0 3px 4px;
  }

  .photoprism-app__gallery {
    padding: 0;
  }

  .photoprism-app__mobile-utility-sheet {
    position: absolute;
    top: calc(100% + 4px);
    right: 0;
    left: 0;
    z-index: 6;
    display: none;
    gap: 8px;
    padding: 8px;
    border: 1px solid rgba(var(--photoprism-accent-rgb), 0.14);
    border-radius: 18px;
    background: color-mix(in srgb, var(--photoprism-panel-strong) 96%, white);
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.08);
  }

  .photoprism-app__mobile-utility-sheet--open {
    display: grid;
  }

  .photoprism-app__mobile-utility-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    color: var(--photoprism-text-muted);
    font-size: 11px;
  }

  .photoprism-app__mobile-utility-group .ant-segmented {
    width: 100%;
  }

  .photoprism-app__mobile-utility-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
  }

  .photoprism-app__gallery--grid.photoprism-app__gallery--density-compact,
  .photoprism-app__gallery--masonry.photoprism-app__gallery--density-compact {
    gap: 4px;
  }

  .photoprism-app__gallery-section {
    gap: 2px;
  }

  .photoprism-app__gallery-section-header {
    flex-wrap: nowrap;
    align-items: center;
    min-height: 42px;
    padding: 6px 1px 4px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }

  .photoprism-app__gallery-section-header--compact {
    align-items: center;
    gap: 6px;
    padding: 6px 1px 3px;
    border-radius: 0;
  }

  .photoprism-app__gallery-section-toggle {
    gap: 8px;
    min-height: 36px;
  }

  .photoprism-app__gallery-section-toggle-check {
    width: 28px;
    min-width: 28px;
    height: 28px;
    font-size: 13px;
  }

  .photoprism-app__gallery-section-heading strong {
    font-size: 13px;
    font-weight: 700;
    color: rgba(154, 52, 18, 0.86);
  }

  .photoprism-app__gallery-section-heading span {
    font-size: 10px;
    opacity: 0.72;
  }

  .photoprism-app__gallery-section-actions {
    width: auto;
    justify-content: flex-end;
    flex-wrap: nowrap;
    gap: 5px;
  }

  .photoprism-app__gallery-section-action {
    min-height: 30px;
    padding-inline: 9px;
    font-size: 10px;
  }

  .photoprism-app__gallery-section-body--grid.photoprism-app__gallery-section-body--density-compact {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 3px;
  }

  .photoprism-app__gallery-section-body--grid.photoprism-app__gallery-section-body--density-comfortable {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4px;
  }

  .photoprism-app__gallery-section-body--grid.photoprism-app__gallery-section-body--density-large {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 5px;
  }

  .photoprism-app__gallery-section-body--masonry.photoprism-app__gallery-section-body--density-compact {
    columns: 3;
    column-gap: 3px;
  }

  .photoprism-app__gallery-section-body--masonry.photoprism-app__gallery-section-body--density-comfortable {
    columns: 3;
    column-gap: 4px;
  }

  .photoprism-app__gallery-section-body--masonry.photoprism-app__gallery-section-body--density-large {
    columns: 2;
    column-gap: 5px;
  }

  .photoprism-app__photo-card {
    touch-action: manipulation;
  }

  .photoprism-app__gallery--list .photoprism-app__photo-card {
    grid-template-columns: 72px minmax(0, 1fr);
    padding: 6px;
    border-radius: 16px;
  }

  .photoprism-app__gallery--list.photoprism-app__gallery--density-large .photoprism-app__photo-card {
    grid-template-columns: 88px minmax(0, 1fr);
  }

  .photoprism-app__photo-thumb-shell {
    border-radius: 4px;
  }

  .photoprism-app__gallery--list .photoprism-app__photo-thumb-shell {
    border-radius: 10px;
  }

  .photoprism-app__photo-meta strong {
    font-size: 11px;
  }

  .photoprism-app__photo-meta span {
    font-size: 10px;
  }

  .photoprism-app__photo-overlay-action {
    width: 26px;
    min-width: 26px;
    height: 26px;
    border-color: rgba(255, 255, 255, 0.52);
    background: rgba(15, 23, 42, 0.12);
    box-shadow:
      inset 0 0 0 1px rgba(255, 255, 255, 0.16),
      0 2px 6px rgba(15, 23, 42, 0.06);
    opacity: 0.54;
  }

  .photoprism-app__photo-detail {
    top: 3px;
    right: 3px;
  }

  .photoprism-app__photo-media-badge {
    left: 3px;
    right: 30px;
    bottom: 3px;
    min-height: 18px;
    padding-inline: 6px;
    gap: 4px;
    font-size: 9px;
  }

  .photoprism-app__photo-check {
    right: 3px;
    bottom: 3px;
  }

  .photoprism-app__photo-favorite {
    top: 3px;
    left: 3px;
  }

  .photoprism-app__toolbar-filter-badge {
    min-width: 16px;
    height: 16px;
    padding-inline: 4px;
    font-size: 9px;
  }

  .photoprism-app__photo-card--selected .photoprism-app__photo-overlay-action,
  .photoprism-app__photo-card:focus-visible .photoprism-app__photo-overlay-action,
  .photoprism-app__photo-card:active .photoprism-app__photo-overlay-action,
  .photoprism-app__photo-favorite--active {
    opacity: 1;
  }

  .photoprism-app__viewer-hint {
    top: 10px;
    max-width: calc(100vw - 40px);
    text-align: center;
    white-space: normal;
  }

  .photoprism-app__viewer-main {
    min-height: 0;
  }

  .photoprism-app__zoom-stage {
    padding: 30px 10px 168px;
  }

  .photoprism-app__viewer-image {
    max-height: calc(100dvh - 196px);
    border-radius: 18px;
  }

  .photoprism-app__viewer-video-frame {
    padding: 30px 10px 168px;
  }

  .photoprism-app__viewer-video {
    max-height: calc(100dvh - 208px);
    border-radius: 18px;
  }

  .photoprism-app__viewer-topbar {
    gap: 8px;
    padding: 12px;
  }

  .photoprism-app__viewer-tabbar {
    gap: 8px;
    flex-wrap: wrap;
  }

  .photoprism-app__viewer-tab {
    min-width: 64px;
    min-height: 36px;
    padding-inline: 14px;
  }

  .photoprism-app__viewer-toolbar {
    gap: 8px;
  }

  .photoprism-app__viewer-theme-menu {
    grid-template-columns: minmax(0, 1fr);
    width: min(320px, calc(100vw - 20px));
    max-height: min(68dvh, 520px);
    padding: 10px;
  }

  .photoprism-app__viewer-theme-menu-item {
    min-height: 64px;
    padding: 10px;
  }

  .photoprism-app__viewer-tab-summary {
    width: 100%;
    margin-left: 0;
    justify-content: flex-start;
    gap: 6px;
    text-align: left;
  }

  .photoprism-app__viewer-tab-summary-item {
    min-height: 26px;
    padding-inline: 9px;
  }

  .photoprism-app__viewer-nav.ant-btn {
    top: auto;
    bottom: 146px;
    width: 42px;
    min-width: 42px;
    height: 42px;
    transform: none;
  }

  .photoprism-app__viewer-nav--previous {
    left: 10px;
  }

  .photoprism-app__viewer-nav--next {
    right: 10px;
  }

  .photoprism-app__viewer-stage-sidecar {
    top: auto;
    right: 12px;
    bottom: 92px;
    left: 12px;
    justify-items: stretch;
    gap: 10px;
  }

  .photoprism-app__viewer-stage-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .photoprism-app__viewer-stage-action.ant-btn {
    width: 100%;
    min-width: 0;
    height: 42px;
    padding-inline: 8px;
    border-radius: 14px;
    gap: 5px;
    font-size: 11px;
  }

  .photoprism-app__viewer-rail {
    bottom: 12px;
    gap: 8px;
    padding: 10px;
    max-width: calc(100vw - 20px);
    border-radius: 20px;
  }

  .photoprism-app__viewer-rail-item {
    width: 54px;
    height: 54px;
    border-radius: 16px;
  }

  .photoprism-app__viewer-panel-head,
  .photoprism-app__viewer-detail-row {
    padding: 12px 0;
  }

  .photoprism-app__viewer-info-page {
    width: calc(100vw - 24px);
    padding: 0 0 120px;
  }

  .photoprism-app__viewer-video-status {
    width: 100%;
  }

  .photoprism-app__viewer-info-hero {
    min-height: 148px;
    border-radius: 16px;
  }

  .photoprism-app__viewer-info-hero img {
    width: 100%;
    max-height: 200px;
  }

  .photoprism-app__viewer-info-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .photoprism-app__viewer-info-actions .ant-btn {
    width: 100%;
  }

  .photoprism-app__viewer-detail-row {
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 10px;
  }

  .photoprism-app__viewer-album-panel {
    padding: 14px;
  }

  .photoprism-app__viewer-album-panel-actions {
    grid-template-columns: minmax(0, 1fr);
  }

  .photoprism-app__viewer-album-panel-actions .ant-btn {
    width: 100%;
  }
}
