/* Helport AI — Printable QR Sheet Generator */
.qr-sheet-section { padding: 18px; }
.qr-sheet-layout {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(320px, 1.15fr);
  gap: 16px;
  align-items: start;
}
.qr-sheet-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin: 12px 0;
}
.qr-sheet-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
}
.qr-sheet-emp-list {
  max-height: 340px;
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
}
.qr-sheet-emp {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
}
.qr-sheet-emp:last-child { border-bottom: 0; }
.qr-sheet-emp:hover { background: var(--surface-hover); }
.qr-sheet-emp.has-qr strong::after {
  content: " · QR";
  color: var(--primary);
  font-weight: 600;
  font-size: 0.72rem;
}
.qr-sheet-emp-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  font-size: 0.86rem;
}
.qr-sheet-emp-body strong {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.qr-sheet-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.qr-sheet-progress { margin-top: 10px; }
.qr-sheet-progress-track {
  height: 6px;
  border-radius: 999px;
  background: var(--border);
  overflow: hidden;
}
.qr-sheet-progress-fill {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--primary-dark), var(--primary));
  transition: width 0.2s ease;
}
.qr-sheet-preview-pane {
  position: sticky;
  top: 12px;
}
.qr-sheet-preview-head {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.qr-sheet-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}
.qr-sheet-zoom-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 0.8rem;
}
.qr-sheet-preview-stage {
  background:
    linear-gradient(145deg, #1e293b 0%, #0f172a 100%);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  padding: 16px;
  min-height: 420px;
  overflow: auto;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}
.qr-sheet-empty {
  padding: 48px 20px;
  text-align: center;
}
.qr-sheet-page {
  width: 210mm;
  min-height: 297mm;
  background: #fff;
  color: #0f172a;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  padding: 10mm;
  flex-shrink: 0;
}
.qr-sheet-grid {
  display: grid;
  grid-template-columns: repeat(4, 4cm);
  grid-template-rows: repeat(5, 4.9cm);
  justify-content: space-between;
  align-content: space-between;
  width: 100%;
  height: 277mm;
}
.qr-sheet-card {
  width: 4cm;
  height: 4.9cm;
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow: hidden;
  text-align: center;
}
.qr-sheet-card.is-empty {
  visibility: hidden;
}
.qr-sheet-qr {
  width: 4cm;
  height: 3.8cm;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
}
.qr-sheet-qr img {
  width: 3.8cm;
  height: 3.8cm;
  object-fit: contain;
}
.qr-sheet-name {
  width: 4cm;
  height: 0.85cm;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10.5pt;
  font-weight: 700;
  line-height: 1.15;
  padding: 0 1mm;
  overflow: hidden;
  word-break: break-word;
  font-family: Arial, Helvetica, sans-serif;
}
.qr-sheet-eid {
  width: 4cm;
  height: 0.25cm;
  font-size: 7pt;
  color: #64748b;
  font-family: Arial, Helvetica, sans-serif;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
html[data-theme="dark"] .qr-sheet-emp-list {
  background: rgba(15, 23, 42, 0.45);
}

@media (max-width: 1100px) {
  .qr-sheet-layout {
    grid-template-columns: 1fr;
  }
  .qr-sheet-preview-pane {
    position: static;
  }
}
