select[data-photo-native], [data-photo-replaced] { display:none !important; }
.lp-photo-picker { width:100%; min-width:0; margin:6px 0 10px; }
.lp-photo-trigger { display:grid; grid-template-columns:56px minmax(0,1fr) 16px; align-items:center; gap:12px; width:100%; min-height:80px; padding:10px; border:1px solid #aeb7bd; border-radius:5px; background:#fff; color:#20252a; font:inherit; font-size:13px; line-height:1.4; letter-spacing:0; text-align:left; cursor:pointer; box-sizing:border-box; }
.lp-photo-trigger:hover { border-color:#130a72; background:#fafbfc; }
.lp-photo-trigger:focus-visible, .lp-photo-option:focus-visible, .lp-photo-close:focus-visible { outline:3px solid #287b99; outline-offset:2px; }
.lp-photo-name { display:block; min-width:0; overflow-wrap:anywhere; font-weight:600; }
.lp-photo-meta { display:block; color:#667078; font-size:11px; font-weight:400; margin-top:3px; }
.lp-photo-thumb { display:flex; align-items:center; justify-content:center; gap:2px; width:56px; height:56px; background:#fff; border:1px solid #e3e7e9; border-radius:4px; overflow:hidden; flex:none; box-sizing:border-box; }
.lp-photo-thumb img { display:block; width:100%; height:100%; object-fit:contain; min-width:0; }
.lp-photo-thumb.is-pair img { width:48%; }
.lp-photo-missing { color:#70787d; font-size:10px; text-align:center; line-height:1.2; padding:2px; }
.lp-photo-dialog { width:min(620px,calc(100% - 24px)); max-width:620px; max-height:calc(100dvh - 24px); margin:auto; padding:0; border:1px solid #c6cdd1; border-radius:8px; background:#fff; color:#20252a; box-shadow:0 16px 50px #0003; font-family:Arial,sans-serif; letter-spacing:0; overflow:hidden; box-sizing:border-box; }
.lp-photo-dialog::backdrop { background:#17202680; }
.lp-photo-dialog[open] { display:flex; flex-direction:column; }
.lp-photo-head { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:16px 18px 12px; flex:none; }
.lp-photo-head h2 { margin:0; color:#20252a; font-size:18px; line-height:1.35; font-weight:700; letter-spacing:0; }
.lp-photo-close { display:grid; place-items:center; width:36px; height:36px; min-height:36px; padding:0; border:1px solid #d8dde0; border-radius:4px; background:#fff; color:#434b51; cursor:pointer; font-size:24px; line-height:1; flex:none; }
.lp-photo-search-wrap { display:block; padding:0 18px 12px; flex:none; }
.lp-photo-search { display:block; width:100%; min-height:44px; padding:10px 12px; border:1px solid #aeb7bd; border-radius:4px; color:#20252a; background:#fff; font:inherit; font-size:14px; box-sizing:border-box; }
.lp-photo-count { padding:0 18px 10px; color:#667078; font-size:12px; flex:none; }
.lp-photo-options { overflow:auto; overscroll-behavior:contain; max-height:520px; min-height:0; padding:0 10px 10px; border-top:1px solid #e2e6e8; }
.lp-photo-group { padding:13px 8px 7px; color:#667078; font-size:11px; font-weight:700; line-height:1.4; }
.lp-photo-option { display:grid; grid-template-columns:56px minmax(0,1fr) 20px; align-items:center; gap:12px; width:100%; min-height:80px; margin:0; padding:10px 8px; color:#20252a; background:#fff; border:0; border-bottom:1px solid #e8ecee; border-radius:0; font:inherit; font-size:13px; line-height:1.4; letter-spacing:0; text-align:left; cursor:pointer; box-sizing:border-box; }
.lp-photo-option:hover { background:#f2f5f6; }
.lp-photo-option[aria-selected="true"] { background:#edf4f7; box-shadow:inset 3px 0 #160a73; }
.lp-photo-option:disabled { opacity:.55; cursor:not-allowed; }
.lp-photo-check { color:#160a73; font-weight:bold; visibility:hidden; font-size:17px; }
.lp-photo-option[aria-selected="true"] .lp-photo-check { visibility:visible; }
.lp-photo-empty { padding:24px 8px; color:#667078; font-size:14px; }
@media (max-width:600px) {
  .lp-photo-dialog { width:calc(100% - 16px); max-height:calc(100dvh - 16px); }
  .lp-photo-head { padding:12px 12px 10px; }
  .lp-photo-head h2 { font-size:17px; }
  .lp-photo-search-wrap { padding:0 12px 10px; }
  .lp-photo-count { padding:0 12px 8px; }
  .lp-photo-options { max-height:calc(100dvh - 180px); padding:0 5px 8px; }
  .lp-photo-option { gap:9px; }
}
@media print { .lp-photo-dialog { display:none !important; } }
