/* Product photo controls are shown only after the server verifies ownership. */
.photo-manage-button,.photo-edit-button,.photo-retry-button{font:inherit;cursor:pointer;color:var(--blue,#4a535b);background:#f5f8fb;border:1px solid #bec1c4;border-radius:5px;font-size:13px;font-weight:600;padding:9px 13px;line-height:1.4}
.photo-management-tools{margin-top:13px}.photo-management-tools:has([hidden]){display:none}
.photo-manage-button:hover,.photo-edit-button:hover,.photo-retry-button:hover{background:#eaedf0;border-color:#919497}
.photo-edit-button{align-self:flex-start;margin-top:17px;padding:7px 11px;font-size:12px;background:#fff}
.photo-manage-button[hidden],.photo-edit-button[hidden],.photo-load-status[hidden]{display:none}
.photo-load-status{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:0 0 20px;padding:12px 15px;border:1px solid #c9cccf;border-radius:5px;background:#eff2f5;font-size:13px;color:#5a5d60}
.photo-retry-button{flex-shrink:0;background:white}
.photo-editor-dialog{--pe-blue:#4a535b;--pe-ink:#292f34;--pe-muted:#59636c;width:min(970px,calc(100vw - 40px));max-width:none;max-height:calc(100dvh - 40px);padding:0;border:1px solid #c4c7ca;border-top:4px solid #8c9397;border-radius:14px;color:var(--pe-ink);background:#f4f7fa;box-shadow:0 28px 90px #23262945;font-family:Arial,Helvetica,sans-serif;line-height:1.5;overflow:auto;overscroll-behavior:contain}
.photo-editor-dialog::backdrop{background:#26292ca8;backdrop-filter:blur(3px)}
.photo-editor-dialog [hidden]{display:none!important}
.photo-editor-dialog button,.photo-editor-dialog input,.photo-editor-dialog select{font:inherit}
.photo-editor-dialog button{cursor:pointer}
.photo-editor-dialog button:disabled{cursor:not-allowed;opacity:.48}
.photo-editor-dialog button:focus-visible,.photo-editor-dialog input:focus-visible,.photo-editor-dialog select:focus-visible,.photo-manage-button:focus-visible,.photo-edit-button:focus-visible,.photo-retry-button:focus-visible{outline:3px solid #94979a;outline-offset:3px}
.pe-header{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;padding:24px 28px 21px;background:#fff;border-bottom:1px solid #dde0e3}
.pe-header h2{font-family:Georgia,serif;font-size:29px;font-weight:400;line-height:1.2;margin:0 0 8px;letter-spacing:0}
.pe-header p{margin:0;font-size:14px;color:var(--pe-muted)}
.pe-header .pe-eyebrow{font-size:10px;letter-spacing:1.8px;font-weight:700;margin:0 0 8px;color:var(--pe-blue)}
.pe-close{display:grid;place-items:center;flex-shrink:0;width:34px;height:34px;padding:0;border:1px solid #d1d4d7;border-radius:7px;background:#fafbfc;color:var(--pe-blue);font-size:25px!important;line-height:1}
.pe-close:hover{background:#eaedf0}
.pe-content{padding:22px 28px 24px}
.pe-product-picker{display:grid;grid-template-columns:.85fr 1.45fr;gap:16px;padding-bottom:21px;border-bottom:1px solid #d9dcdf;margin-bottom:22px}
.pe-field{display:flex;flex-direction:column;gap:6px;min-width:0;font-size:12px;font-weight:700;color:#4f5255}
.pe-field input,.pe-field select{min-width:0;width:100%;border:1px solid #c2c5c8;border-radius:6px;padding:10px 12px;background:white;color:var(--pe-ink);font-size:14px;font-weight:400;line-height:1.4;min-height:42px}
.pe-field select{padding-right:24px}
.pe-columns{display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,1fr);gap:26px;align-items:start}
.pe-tools{min-width:0}
.pe-tabs{display:flex;gap:3px;padding:4px;border:1px solid #d2d5d8;border-radius:8px;background:#e8ecef;margin:0 0 17px}
.pe-tab{flex:1;min-width:0;border:1px solid transparent;border-radius:5px;padding:9px 8px;font-size:13px!important;font-weight:600!important;background:transparent;color:#616467;line-height:1.35}
.pe-tab[aria-selected=true]{border-color:#c3c6c9;background:#fff;color:#424548;box-shadow:0 1px 3px #3235380d}
.pe-dropzone{display:flex;flex-direction:column;align-items:center;text-align:center;border:1px dashed #a7aaad;border-radius:9px;padding:26px 20px 20px;background:#fff;min-height:265px;transition:background .15s,border-color .15s}
.pe-dropzone.pe-dragover{border:2px solid #707376;background:#eef1f4}
.pe-upload-symbol{display:grid;place-items:center;width:43px;height:43px;background:#eaedf0;color:#727578;border:1px solid #d0d3d6;border-radius:12px;font-size:26px;line-height:1;margin-bottom:12px}
.pe-dropzone h3{font-size:17px;line-height:1.35;margin:0 0 7px;font-weight:600}
.pe-dropzone>p{font-size:13px;color:var(--pe-muted);margin:0 0 17px}
.pe-button{border:1px solid #c1c4c7;border-radius:6px;padding:10px 16px;font-size:13px!important;font-weight:600!important;background:#fff;color:var(--pe-blue);line-height:1.4;min-height:41px}
.pe-button:hover:not(:disabled){background:#ebeef1}
.pe-button-primary{border-color:#4a535b;background:#4a535b;color:white;white-space:nowrap}
.pe-button-primary:hover:not(:disabled){border-color:#44474a;background:#44474a}
.pe-file-input{display:none}
.pe-dropzone .pe-file-status{font-size:11px;line-height:1.5;margin:15px 0 0;overflow-wrap:anywhere;max-width:100%}
.pe-help{font-size:12px;color:var(--pe-muted);line-height:1.6;margin:12px 1px 0}
.pe-preview-heading{font-size:11px;text-transform:uppercase;font-weight:700;letter-spacing:1px;color:#66696c;margin:4px 0 11px}
.pe-preview-card{margin:0;box-shadow:0 2px 8px #2e31340a!important;border-radius:6px}
.pe-preview .pe-preview-media{height:200px;min-height:200px;flex-shrink:0}
.pe-preview .product-body{padding:19px}
.pe-preview .product h3{font-size:18px;line-height:1.35;margin:11px 0 8px}
.pe-preview .product p{font-size:13px;margin:0 0 15px}
.pe-preview .category{font-size:10px;line-height:1.5}
.pe-preview-link{display:block;width:100%;padding:10px 14px;text-align:center;background:#4a535b;color:white;border-radius:4px;font-size:13px;font-weight:700;line-height:1.4}
.pe-preview .product-photo-credit{margin-top:9px;display:block;text-align:center;font-size:10px;color:var(--pe-muted)}
.pe-preview .product-affiliate{display:block;text-align:center;font-size:10px;color:var(--pe-muted)}
.pe-gallery-count{font-size:11px;color:#6a6d70;margin:9px 0}
.pe-gallery-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;max-height:360px;overflow-y:auto;overscroll-behavior:contain;padding:3px 3px 6px;margin:-3px}
.pe-gallery-item{border:1px solid #cdd0d3;border-radius:6px;background:#fff;overflow:hidden;padding:7px;text-align:left;min-width:0;color:#4c4f52}
.pe-gallery-item[aria-pressed=true]{border:2px solid #65686b;padding:6px;background:#eceff2;box-shadow:0 0 0 1px #65686b30}
.pe-gallery-item:hover:not(:disabled){border-color:#85888b;background:#f2f5f8}
.pe-gallery-item img{display:block;width:100%;height:80px;object-fit:contain;background:#fff;border-radius:3px}
.pe-gallery-name{display:block;font-size:10px;line-height:1.4;margin:7px 0 1px;overflow-wrap:anywhere}
.pe-gallery-missing{display:grid;place-items:center;height:80px;font-size:10px;color:#777a7d}
.pe-empty{padding:24px 12px;margin:0;text-align:center;color:#74777a;font-size:13px;line-height:1.6;grid-column:1/-1}
.pe-footer{position:sticky;bottom:0;padding:14px 28px 19px;border-top:1px solid #d2d5d8;background:#fff;z-index:2;box-shadow:0 -4px 16px #2e313404}
.pe-action-status{min-height:18px;margin:0 0 11px;font-size:12px;color:#37654e;line-height:1.5}
.pe-action-status:empty{display:none}
.pe-action-status.pe-error{color:#9a392f}
.pe-footer-actions{display:flex;align-items:center;justify-content:space-between;gap:14px}
.pe-restore{padding-left:0;padding-right:0;border-color:transparent;background:transparent;font-size:12px!important;text-decoration:underline;text-underline-offset:3px}
.pe-restore:hover:not(:disabled){background:transparent;color:#333639}
.pe-final-actions{display:flex;gap:9px;margin-left:auto}
@media(max-width:700px){.photo-editor-dialog{width:calc(100vw - 24px);max-height:calc(100dvh - 24px);border-radius:11px}.pe-header{padding:20px}.pe-header h2{font-size:25px}.pe-content{padding:18px 20px}.pe-product-picker{grid-template-columns:1fr;gap:11px}.pe-columns{gap:19px;grid-template-columns:1fr 1fr}.pe-tabs{gap:0;padding:3px}.pe-tab{font-size:12px!important;padding:8px 4px}.pe-dropzone{padding:20px 11px;min-height:250px}.pe-dropzone h3{font-size:15px}.pe-gallery-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.pe-preview .pe-preview-media{height:175px;min-height:175px;padding:14px}.pe-preview .product-body{padding:15px}.pe-preview .product h3{font-size:16px}.pe-footer{padding:13px 20px 17px}}
@media(max-width:500px){.photo-load-status{align-items:flex-start;flex-direction:column;gap:8px}.photo-editor-dialog{width:calc(100vw - 16px);max-height:calc(100dvh - 16px)}.pe-header{padding:17px}.pe-header h2{font-size:23px}.pe-header p{font-size:12px}.pe-content{padding:16px}.pe-columns{grid-template-columns:1fr;gap:21px}.pe-tabs{margin-bottom:13px}.pe-tab{font-size:13px!important}.pe-dropzone{min-height:220px;padding:21px 18px}.pe-dropzone h3{font-size:17px}.pe-gallery-grid{grid-template-columns:repeat(3,minmax(0,1fr));max-height:290px}.pe-preview .pe-preview-media{height:185px;min-height:185px}.pe-preview .product-body{padding:17px}.pe-preview .product h3{font-size:18px}.pe-preview-column>.pe-help{margin-top:8px}.pe-footer{padding:12px 16px 15px}.pe-footer-actions{align-items:stretch;flex-wrap:wrap;gap:6px}.pe-restore{text-align:left}.pe-final-actions{margin-left:auto}.pe-button{padding:10px 12px}.pe-action-status{font-size:12px}}
@media(prefers-reduced-motion:reduce){.pe-dropzone{transition:none}}

/* Match the owner controls to Miles & Manuals. */
.photo-editor-dialog{--pe-blue:#4a535b;--pe-ink:#292f34;--pe-muted:#59636c;border-top-color:#8c9397;background:#f3f4f5}
.pe-button-primary,.pe-preview-link{background:#4a535b;border-color:#4a535b;color:#fff}
.pe-button-primary:hover:not(:disabled){background:#34393e;border-color:#34393e}
.photo-manage-button,.photo-edit-button,.photo-retry-button{background:#f2f5f8;color:#4a535b;border-color:#b4bdc4}
.pe-tabs,.pe-upload-symbol{background:#e8ecef}
