body:has(#work-editor[open]){overflow:hidden}
.artwork-workspace #work-editor{
  width:min(960px,calc(100% - 40px));max-width:none;
  max-height:calc(100dvh - 40px);padding:0;
  border:1px solid #e1dfdb;border-radius:10px;
  scroll-padding-block:72px 16px;overscroll-behavior:contain
}
#work-editor::backdrop{background:rgb(25 24 22 / 58%)}
.work-editor-bar{
  position:sticky;top:0;z-index:3;display:grid;
  grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:10px;
  padding:8px 18px;border-bottom:1px solid #e9e7e3;background:#fff
}
.work-editor-bar #editor-title{
  font-size:17px;font-weight:600;line-height:1.35;
  text-align:center;outline:none;word-break:keep-all
}
.work-editor-bar #work-editor-close{
  width:44px;height:44px;border-radius:4px;line-height:1
}
.work-editor-bar #work-editor-close:hover{background:#f5f3f0}
.work-editor-bar #save-work{
  min-height:44px;padding:5px 13px;border-radius:5px;
  font-size:13px;font-weight:600;white-space:nowrap
}
#editor-feedback:not(:empty){margin:12px clamp(16px,3vw,28px) 0}
#work-form{
  display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);
  align-items:start;gap:clamp(20px,3.7vw,40px);padding:clamp(16px,3vw,28px)
}
.work-editor-media,.work-editor-fields{min-width:0}
.work-editor-photo-label{
  position:relative;inset:auto;transform:none;display:block;
  padding:0;min-height:0;border:0;border-radius:7px;white-space:normal
}
.work-editor-photo-frame{
  display:grid;place-items:center;width:100%;height:clamp(200px,50dvh,440px);
  grid-template:minmax(0,1fr) / minmax(0,1fr);
  min-width:0;overflow:hidden;border:1px solid #eae7e1;border-radius:inherit;
  background:#f7f6f3
}
.work-editor-photo-frame #image-preview{display:block;width:100%;height:100%;object-fit:contain}
.work-editor-photo-empty{
  display:grid;place-items:center;gap:10px;padding:14px;
  color:#4e4b47;text-align:center;font-size:14px
}
.work-editor-add-mark{
  display:grid;place-items:center;width:40px;height:40px;
  border:1px solid #c9c4bc;border-radius:50%;background:#fff;
  color:#3e3a35;font-size:24px;line-height:1
}
.work-editor-photo-change{
  position:absolute;right:7px;bottom:7px;display:grid;align-items:center;
  min-height:34px;padding:4px 11px;border:1px solid #e0dcd5;border-radius:5px;
  background:#fff;color:#45413d;font-size:12px
}
.work-editor-photo-label:has(#image-preview[hidden]) .work-editor-photo-change{display:none}
.work-editor-photo-label:has(#image-preview[hidden]) .work-editor-photo-frame{border-style:dashed;border-color:#d4d0c9}
.work-editor-photo-label:hover .work-editor-photo-change,
.work-editor-photo-label:hover .work-editor-add-mark{background:#f3f1ed}
#work-editor .work-editor-photo-help{margin:7px 0 14px;color:#666}
#work-editor .work-thumbnail-settings{
  padding:0 12px;border:1px solid #eae7e1;border-radius:6px;
  background:#fbfaf8
}
.work-thumbnail-settings summary{
  min-height:44px;padding:11px 2px;color:#45413d;cursor:pointer;font-size:12px
}
.work-thumbnail-settings summary:focus-visible{outline:1px solid #555;outline-offset:2px}
.work-thumbnail-settings[open] .work-thumbnail-layout{padding:4px 0 10px}
.work-editor-fields .field{min-width:0;margin-bottom:16px}
.work-editor-fields .field>label,.work-editor-fields .work-categories legend{
  margin-bottom:5px;color:#45413d;font-weight:600
}
.work-editor-fields .field input:not([type=checkbox]),.work-editor-fields .field select,.work-editor-fields .field textarea{
  border-color:#e3e0da;border-radius:5px
}
.work-editor-fields .work-editor-title-field input{font-size:16px;font-weight:600}
.work-editor-fields .work-caption-fields{
  grid-template-columns:minmax(0,1.5fr) minmax(0,1.05fr) minmax(74px,.68fr)
}
.work-editor-fields .work-editor-copy,
.work-editor-fields .work-editor-details,
.work-editor-fields .work-editor-publishing{padding-top:16px;border-top:1px solid #eae7e1}
.work-editor-section-heading{
  display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px;margin-bottom:5px
}
.work-editor-section-heading h3{font-size:15px;font-weight:600}
#work-editor .work-editor-detail-picker{min-height:44px;padding:6px 13px;border-radius:5px}
#work-editor .work-editor-details{margin:5px 0 18px}
#work-editor .work-editor-details > .field-help{margin:0 0 8px;word-break:keep-all}
.work-editor-secondary-actions{
  display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px;margin-top:12px
}
.work-editor-secondary-actions .button{border-radius:5px}
.work-editor-secondary-actions .quiet-button{min-height:44px}

@media(max-width:719px){
  #work-form{grid-template-columns:minmax(0,1fr);gap:20px}
  .work-editor-photo-frame{height:auto;aspect-ratio:1.2;max-height:min(440px,49dvh);min-height:155px}
  .work-editor-photo-frame #image-preview{min-height:0}
  .work-editor-fields .field input:not([type=checkbox]),.work-editor-fields .field select,.work-editor-fields .field textarea{font-size:16px}
}
@media(max-width:540px){
  .artwork-workspace #work-editor{
    width:100%;height:100dvh;max-height:100dvh;margin:0;
    border:0;border-radius:0
  }
  .work-editor-bar{padding:6px 12px;padding-top:max(6px,env(safe-area-inset-top))}
  #work-form{padding:14px;padding-bottom:max(24px,env(safe-area-inset-bottom))}
  #editor-feedback:not(:empty){margin-inline:14px}
}
@media(max-width:390px){
  .work-editor-fields .work-caption-fields{
    grid-template-columns:minmax(0,1.3fr) minmax(0,1fr);gap:0 8px
  }
  .work-caption-fields .work-editor-material{grid-column:1/-1}
}
