.drawing-reference__image { position: relative; }
.drawing-reference__badge { position: absolute; bottom: 5px; left: 5px; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 8px; background: #fffdf4ec; color: #247f76; box-shadow: 0 2px 7px #23433b15; font-size: 18px; line-height: 1; }
.drawing-gallery { width: min(840px, calc(100% - 24px)); }
.drawing-gallery .drawing-dialog__body { padding: 18px; text-align: right; }
.drawing-gallery__header { display: flex; align-items: center; gap: 12px; padding-inline-end: 40px; margin-bottom: 15px; }
.drawing-gallery__header h2 { margin: 0; font-size: 18px; }
.drawing-gallery__header > span { border-radius: 20px; padding: 4px 9px; font-size: 10px; font-weight: 700; background: #e9f1e6; color: #247f76; white-space: nowrap; }
.drawing-model-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.drawing-model { position: relative; display: grid; align-content: center; justify-items: center; gap: 6px; min-width: 0; padding: 8px 5px; border: 2px solid #e4e8df; border-radius: 16px; background: #fff; color: #334e56; cursor: pointer; transition: transform .18s, border-color .18s, box-shadow .18s, background .18s; }
.drawing-model img { display: block; width: 100%; height: clamp(70px, 12vh, 108px); object-fit: contain; pointer-events: none; }
.drawing-model > span { font-size: 11px; font-weight: 700; line-height: 1.7; text-align: center; }
.drawing-model:hover { transform: translateY(-2px); border-color: #72b3a2; background: #f7fbf5; box-shadow: 0 5px 15px #247f7618; }
.drawing-model[aria-pressed="true"] { border-color: #247f76; background: #edf6e9; box-shadow: 0 0 0 2px #247f7610; }
.drawing-model__check { position: absolute; top: 5px; left: 5px; display: none; place-items: center; width: 21px; height: 21px; border-radius: 50%; background: #247f76; color: #fff; font-size: 13px; }
.drawing-model[aria-pressed="true"] .drawing-model__check { display: grid; }
.drawing-gallery__actions { display: flex; justify-content: space-between; gap: 12px; margin-top: 15px; }
@media (max-width: 650px) {
  .drawing-gallery .drawing-dialog__body { padding: 14px; }
  .drawing-model-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .drawing-model { border-radius: 13px; padding: 7px 3px; }
  .drawing-model img { height: 84px; }
  .drawing-gallery__header { gap: 7px; }
  .drawing-gallery__header h2 { font-size: 15px; }
  .drawing-gallery__header > span { padding: 3px 7px; }
  .drawing-reference__badge { width: 19px; height: 19px; bottom: 2px; left: 2px; border-radius: 6px; font-size: 15px; }
}
@media (max-width: 340px) { .drawing-model-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (prefers-reduced-motion: reduce) { .drawing-model { transition: none; } }
