:root {
  --bg: #0a0b12;
  --text: #f1f1f4;
  --text-dim: rgba(241, 241, 244, 0.62);
  --accent: #8b7cf6;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family:
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  padding: 1.5rem;
}

.print-header {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}

.back-link {
  color: var(--text-dim);
  text-decoration: none;
  font-size: 0.9rem;
}

.back-link:hover {
  color: var(--text);
}

.print-header h1 {
  flex: 1;
  margin: 0;
  font-size: 1.25rem;
}

.print-header button {
  padding: 0.55rem 1.1rem;
  border-radius: 0.6rem;
  border: 1px solid var(--accent);
  background: rgba(139, 124, 246, 0.12);
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
}

.print-header button:hover {
  background: rgba(139, 124, 246, 0.22);
}

.print-status {
  color: var(--text-dim);
}

.qr-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1.25rem;
  max-width: 900px;
}

.qr-tile {
  background: #fff;
  color: #111;
  border-radius: 0.75rem;
  padding: 1.25rem 1rem;
  text-align: center;
}

.qr-tile__code svg {
  width: 100%;
  height: auto;
  display: block;
}

.qr-tile__label {
  margin: 0.9rem 0 0.15rem;
  font-weight: 700;
  font-size: 0.95rem;
}

.qr-tile__title {
  margin: 0;
  font-size: 0.85rem;
  color: #555;
}

@media print {
  body {
    background: #fff;
    color: #000;
    padding: 0;
  }

  .print-header,
  .print-status {
    display: none;
  }

  .qr-grid {
    max-width: none;
    grid-template-columns: repeat(3, 1fr);
  }

  .qr-tile {
    break-inside: avoid;
    border: 1px solid #ddd;
  }
}
