/* Load after portal.css and yacht-wizard.css. Shared standalone and draft photo workspace. */
.pm-gallery, .yacht-photo-gallery.pm-gallery, .yw-gallery.pm-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 16px; margin: 20px 0; }
.pm-card, .yacht-photo-card.pm-card, .yw-photo.pm-card { position: relative; min-width: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0; overflow: hidden; border: 1px solid #dce5e5; border-radius: 14px; background: #fff; }
.pm-frame { position: relative; order: -1; aspect-ratio: 4 / 3; width: 100%; overflow: hidden; display: grid; place-items: center; background: #edf2f2; }
.pm-card .pm-frame img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; border-radius: 0; object-fit: cover; background: #edf2f2; }
.pm-card figcaption { padding: 12px 14px 6px; overflow-wrap: anywhere; font-size: 16px; color: #304957; }
.pm-card .pm-actions { display: flex; flex-wrap: wrap; gap: 8px; padding: 8px 12px 12px; margin-top: auto; }
.pm-card button { min-height: 44px; padding: 8px 10px; font: inherit; font-size: 15px; border-radius: 10px; border: 1px solid #dce5e5; background: #fff; color: #172d43; cursor: pointer; }
.pm-card button:hover:not(:disabled) { border-color: #5a9c92; background: #f0f8f6; }
.pm-card button:disabled, .pm-picker button:disabled { opacity: .55; cursor: not-allowed; }
.pm-main-badge { position: absolute; top: 10px; left: 10px; z-index: 1; padding: 5px 10px; border-radius: 999px; background: #172d43; color: #fff; font-size: 15px; font-weight: 600; box-shadow: 0 2px 6px #172d4320; }
.pm-card[data-photo-main="true"] { border-color: #5a9c92; box-shadow: 0 0 0 1px #5a9c92; }
.pm-picker { position: relative; padding: 22px; text-align: center; border: 1px dashed #8faeaa; border-radius: 14px; background: #f6faf9; }
.pm-picker[data-dragging="true"] { border-color: #287c70; background: #e6f4ef; }
.pm-drop-hint { margin: 0 0 14px; color: #304957; font-weight: 550; }
.pm-hint { margin: 12px 0 0; color: #596764; font-size: 15px; }
.pm-picker .pm-add { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 10px 20px; border: 1px solid #172d43; border-radius: 999px; background: #172d43; color: #fff; font: inherit; cursor: pointer; }
.pm-picker .pm-file-input, .yacht-wizard .pm-picker .pm-file-input { position: absolute; width: 1px; height: 1px; min-height: 0; padding: 0; border: 0; clip-path: inset(50%); overflow: hidden; }
.pm-picker:focus-within { outline: 3px solid #75c4b8; outline-offset: 3px; }
.pm-card button:focus-visible, .pm-picker button:focus-visible { outline: 3px solid #75c4b8; outline-offset: 2px; }
.pm-skeleton { display: grid; place-items: center; width: 100%; height: 100%; min-height: 145px; color: #5a6f74; font-size: 15px; background: linear-gradient(100deg, #edf2f2 20%, #f8fbfa 45%, #edf2f2 70%); background-size: 220% 100%; animation: pm-loading 1.5s ease-in-out infinite; }
.pm-image-error { padding: 18px; color: #596764; font-size: 15px; text-align: center; }
.pm-local progress { display: block; width: calc(100% - 28px); height: 8px; margin: 8px 14px; accent-color: #287c70; }
.pm-file-status, .pm-file-error { margin: 4px 14px 8px; font-size: 15px; }
.pm-file-error { color: #943e2e; }
.pm-card .pm-remove { align-self: flex-start; margin: 4px 14px 14px; }
@keyframes pm-loading { from { background-position: 100% 0; } to { background-position: -100% 0; } }
@media (prefers-reduced-motion: reduce) { .pm-skeleton { animation: none; } }
@media (max-width: 480px) { .pm-gallery, .yacht-photo-gallery.pm-gallery, .yw-gallery.pm-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } .pm-card figcaption { padding: 10px; } .pm-picker { padding: 18px 12px; } }
@media (max-width: 340px) { .pm-gallery, .yacht-photo-gallery.pm-gallery, .yw-gallery.pm-gallery { grid-template-columns: 1fr; } }
