.print-cards-dialog {
  width: min(1160px, calc(100vw - 32px));
  max-width: none;
  max-height: calc(100dvh - 32px);
  padding: 0;
  border: 0;
  border-radius: 14px;
  overflow-y: auto;
  background: #fff;
  color: #182238;
  box-shadow: 0 24px 80px #18223840;
}
.print-cards-dialog-mask { background: #18223866; padding: 8px; }
.print-cards-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  position: sticky;
  top: 0;
  z-index: 2;
  padding: 16px 24px;
  border-bottom: 1px solid #e6eaf0;
  background: #fff;
}
.print-cards-dialog-head h2 { margin: 0; font-size: 18px; }
.print-cards-dialog-head button { min-height: 40px; }
.print-cards-dialog-body { padding: 0 24px 20px; }
.print-cards-surface { min-width: 0; }
.print-cards-surface .print-card-save-template { margin-top: 22px; margin-bottom: 20px; }
.print-cards-surface .print-card-template-status:empty { min-height: 0; margin: 0; }
.print-cards-surface .print-card-paper-stage { min-height: 340px; }
.print-cards-surface .print-card-pages { margin-bottom: 18px; flex-wrap: wrap; }
.print-cards-surface .print-card-pages[hidden] { display: none; }
.print-cards-surface .print-card-pages button { flex: 0 0 auto; min-width: 72px; }
.print-cards-surface .print-card-template-list { grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); }
@media (max-width: 800px) {
  .print-cards-dialog { width: calc(100vw - 16px); max-height: calc(100dvh - 16px); }
  .print-cards-dialog-head { padding: 12px 16px; }
  .print-cards-dialog-body { padding: 0 16px 16px; }
  .print-cards-surface .print-card-paper-stage { min-height: 240px; padding: 16px; }
  .print-cards-surface .print-card-template-head { flex-wrap: wrap; }
}
