/* shared/request-photo.css — EJRequestPhoto's picker. feat/plant-request-photos (2026-11-08).
 *
 * Mobile-first and measured, not eyeballed: tools/plant-request-photo-tests/layout.test.mjs drives a
 * real headless Chrome at 320 / 360 / 375 / 430px and asserts the picker, every thumb and every
 * Remove control is fully on screen, that the page never scrolls sideways, and that every tap target
 * is at least 44px. The standing rule from fix/pos-narrow-topbar applies: a clipped row with no
 * scroll affordance is a defect, so the tiles WRAP — they are never a sideways rail.
 *
 * Colours come from each page's own variables (both the shop and the account page are the neon
 * theme), and `.ejrp-cyan` / `.ejrp-yellow` let the host page keep its own accent.
 */
.ejrp { display: flex; flex-direction: column; gap: 10px; max-width: 100%; box-sizing: border-box; }
.ejrp * { box-sizing: border-box; }

/* WRAPS. Never overflow-x. */
.ejrp-tiles { display: flex; flex-wrap: wrap; gap: 10px; max-width: 100%; }

.ejrp-tile {
  width: 104px; max-width: 100%; display: flex; flex-direction: column; gap: 6px;
  background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 14px; padding: 8px;
}
.ejrp-thumb { width: 100%; height: 86px; object-fit: cover; border-radius: 10px; display: block; background: rgba(0, 0, 0, 0.3); }
.ejrp-blank { background: rgba(255, 255, 255, 0.08); }
.ejrp-state { font-size: 0.66rem; font-weight: 900; letter-spacing: 0.3px; color: rgba(245, 245, 250, 0.82); text-align: center; }
.ejrp-err .ejrp-state { color: #ffb3a8; }
.ejrp-err { border-color: rgba(192, 57, 43, 0.55); }

/* Real progress, from the XHR's own upload event. */
.ejrp-bar { height: 5px; border-radius: 3px; background: rgba(255, 255, 255, 0.16); overflow: hidden; }
.ejrp-bar > i { display: block; height: 100%; background: currentColor; transition: width 0.18s linear; }

/* ≥44px tap targets, both controls. */
.ejrp-x, .ejrp-add {
  min-height: 44px; border-radius: 999px; font-family: inherit; font-weight: 900; cursor: pointer;
  background: rgba(255, 255, 255, 0.08); color: #fff; border: 1px solid rgba(255, 255, 255, 0.22);
  padding: 8px 10px; font-size: 0.72rem; width: 100%;
}
.ejrp-add { align-self: flex-start; width: auto; max-width: 100%; padding: 10px 18px; font-size: 0.86rem; }
.ejrp-x:hover { border-color: rgba(192, 57, 43, 0.6); color: #ffb3a8; }

.ejrp-hint { font-size: 0.74rem; font-weight: 700; color: rgba(245, 245, 250, 0.74); line-height: 1.45; }
.ejrp-msg { font-size: 0.8rem; font-weight: 800; color: var(--yellow, #ffe600); line-height: 1.45; }

.ejrp-cyan { color: var(--cyan, #00c8ff); }
.ejrp-yellow { color: var(--yellow, #ffe600); }
.ejrp-cyan .ejrp-add:hover { border-color: var(--cyan, #00c8ff); color: var(--cyan, #00c8ff); }
.ejrp-yellow .ejrp-add:hover { border-color: var(--yellow, #ffe600); color: var(--yellow, #ffe600); }
.ejrp-add:focus-visible, .ejrp-x:focus-visible { outline: 3px solid var(--cyan, #00c8ff); outline-offset: 2px; }

/* The photos already on a request, wherever they are shown back (the customer's own tracker, and
   the admin card's bigger-than-96px thumbs). Wraps for the same reason. */
.ejrp-shots { display: flex; flex-wrap: wrap; gap: 8px; max-width: 100%; margin-top: 8px; }
.ejrp-shot {
  display: block; width: 140px; max-width: 100%; min-height: 44px; border-radius: 12px; overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18); background: rgba(0, 0, 0, 0.25);
}
.ejrp-shot img { display: block; width: 100%; height: 140px; object-fit: cover; }
@media (max-width: 359px) { .ejrp-shot { width: 120px; } .ejrp-shot img { height: 120px; } }
