/**
 * Property photos card — tile + remove-button styles (2026-08-12 Chris)
 *
 * Chris smoke: "the photo that is on the quote was one i used for a
 * placeholder and there is no way to delete it in the editor."
 *
 * The picker rendered a <button class="btn-icon">✕</button>, but .btn-icon
 * is not defined anywhere in the app's CSS. Combined with the parent's
 * global button reset (base.css: `button { background:none; border:none }`),
 * the remove button was effectively invisible — a plain ✕ glyph on the
 * same background as the tile label, hard to see and impossible to hit
 * reliably on mobile.
 *
 * Fix: give the remove button a visible circular chip and float it in the
 * top-right corner of the thumbnail. Also style the tile itself so the
 * label row lines up cleanly.
 *
 * All rules are scoped to [data-qb-photos-list] so nothing else on the
 * page is affected.
 */

[data-qb-photos-list] .qb-photo-tile {
  position: relative;
  border: 1px solid var(--border, #d4d1ca);
  border-radius: 8px;
  overflow: hidden;
  background: var(--surface-2, #f9f8f5);
}

[data-qb-photos-list] .qb-photo-tile img {
  width: 100%;
  height: 120px;
  object-fit: cover;
  display: block;
}

[data-qb-photos-list] .qb-photo-tile-label {
  padding: var(--space-2, 8px) var(--space-3, 12px);
  font-size: 14px;
  color: var(--text, #28251d);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

[data-qb-photos-list] .qb-photo-tile-label .chip {
  margin-left: 6px;
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(67, 122, 34, 0.14);
  color: var(--success, #437a22);
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.02em;
}

/* Remove button — visible chip in the top-right corner of the thumbnail.
 * Sized for touch (32×32) and given real background + shadow so it stands
 * out against any photo. Hover/focus darkens to signal it's clickable. */
[data-qb-photos-list] .qb-photo-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.1);
  background: rgba(255, 255, 255, 0.94);
  color: var(--text, #28251d);
  font-size: 16px;
  line-height: 1;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  transition: background 0.12s ease, color 0.12s ease, transform 0.12s ease;
  padding: 0;
  z-index: 2;
}

[data-qb-photos-list] .qb-photo-remove:hover,
[data-qb-photos-list] .qb-photo-remove:focus-visible {
  background: var(--error, #a12c7b);
  color: #ffffff;
  transform: scale(1.05);
  outline: none;
}

[data-qb-photos-list] .qb-photo-remove:active {
  transform: scale(0.95);
}
