/* Platform crop-modal CSS - THE companion of platform/crop.js (RatioCrop modal).
   Lives with the platform module on purpose: any app importing crop.js links
   this file and gets the modal fully styled - no per-app porting, no drift
   (nails shipped with the modal unstyled exactly because the rules sat in
   hair's stylesheet). Extracted verbatim from hair style.css. */
/* ratio crop modal (crop.js RatioCrop) - above everything, it is modal */
.cropOverlay {
  /* fully opaque: translucent dark over the LIGHT page washed out on the
     phone (and is exactly what dark-mode filters love to mangle) */
  position: fixed; inset: 0; z-index: 120; background: #0a0c10;
  display: flex; flex-direction: column; padding: 12px 12px 14px;
}

.cropHead { color: #fff; text-align: center; margin: 2px 0 10px; font-size: 14px; }

/* overflow:hidden is NOT cosmetic: .cropFrame's dimming box-shadow has a
   9999px spread and .cropFrame is position:absolute, so it paints ABOVE the
   non-positioned header/buttons and used to wash out the whole modal
   (everything outside the crop box ×0.45 - the "faded modal" on the S21,
   root-caused 2026-10-08). Clipping to the stage keeps the dim on the
   photo only. */
.cropStage { position: relative; flex: 1; min-height: 0; overflow: hidden; }

.cropStage img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: contain; user-select: none;
}

/* white border + black ring (visible on any photo) + dim everything outside
   via a huge spread shadow; drag anywhere on the box */
.cropFrame {
  position: absolute; cursor: grab; touch-action: none;
  border: 2px solid #fff;
  box-shadow: 0 0 0 2px #000, 0 0 0 9999px rgba(0, 0, 0, 0.55);
}

.cropFrame:active { cursor: grabbing; }

.cropActions { display: flex; gap: 10px; justify-content: center; margin-top: 12px; }

/* Crop = the primary action (blue like generate); Cancel must stay readable
   on the dark modal (base button style is white-bg/dark-text) */
.cropConfirm { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 600; }

.cropCancel { background: #2b2438; border-color: #8f6bb0; color: #fff; }
@media (hover: hover) {.cropConfirm:hover:not(:disabled) { background: #f06fa8; }
.cropCancel:hover:not(:disabled) { background: #2c313a; }
}
