/* Family moments (D-029): an invite's QR code and an artist's birthday.
   Only the tokens of style.css; the code itself is always black on white,
   by day and by night, because that is what a camera reads best. */

/* ---------- The invite as a QR code ---------- */
.invite-qr {
  margin: 1.5rem 0 0;
  display: grid;
  justify-items: center;
  gap: 0.75rem;
}
.invite-qr-code,
.qr-full-code {
  line-height: 0;
  background: #fff;
  border-radius: 12px;
  box-shadow: var(--mat-shadow);
}
.invite-qr-code { width: min(100%, 20rem); }
.qr-full-code { width: min(92vw, 78vh, 36rem); }
svg.qr { display: block; width: 100%; height: auto; border-radius: inherit; }
/* The interface's line icons give every svg a stroke; a module must stay
   exactly one square, or the code blurs into blobs no camera reads. */
svg.qr, svg.qr * { stroke: none; }
.invite-qr figcaption { max-width: 28rem; text-align: center; font-size: 0.9rem; }

.invite-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  margin: 1.25rem 0 0;
}
.invite-actions :is(button, .button) { display: inline-flex; align-items: center; gap: 0.4rem; min-height: 2.75rem; }
.invite-actions .icon { width: 1.15rem; height: 1.15rem; }

/* Full screen: a white page with the code as large as it fits. It works
   without JavaScript through :target; with it, the page also asks for the
   real full screen and to keep the screen awake (invite-qr.js). */
.qr-full {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  padding: max(1rem, env(safe-area-inset-top)) 1rem max(1rem, env(safe-area-inset-bottom));
  background: #fff;
  color: #1d1b18;
  color-scheme: light;
}
.qr-full:target,
.qr-full.is-open { display: flex; }
.qr-full .qr-full-code { box-shadow: none; }
.qr-full-hint { margin: 0; max-width: 26rem; text-align: center; font-size: 1rem; color: #4d4943; }
.qr-full .button {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 2.75rem;
  color: #1d1b18;
  background: #fff;
  border-color: #1d1b18;
}
.qr-full .icon { width: 1.15rem; height: 1.15rem; }
html:has(.qr-full:target, .qr-full.is-open) { overflow: hidden; }

/* ---------- The artist's birthday ---------- */
.birthday {
  position: relative;
  margin: 0 0 clamp(2rem, 5vw, 3.5rem);
  padding: clamp(1.25rem, 3vw, 2rem);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
}
.birthday .eyebrow { display: inline-flex; align-items: center; gap: 0.4rem; margin: 0 0 0.35rem; }
.birthday .eyebrow .icon { width: 1.1rem; height: 1.1rem; }
.birthday h2 {
  margin: 0 0 1rem;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.9rem, 5vw, 2.8rem);
  line-height: 1.05;
  overflow-wrap: anywhere;
}
.birthday + .birthday { margin-top: calc(clamp(2rem, 5vw, 3.5rem) * -0.5); }
.birthday-strip {
  list-style: none;
  margin: 0 0 0.6rem;
  padding: 0.25rem 0 0.75rem;
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  overscroll-behavior-x: contain;
}
.birthday-strip li { flex: 0 0 auto; scroll-snap-align: start; }
.birthday-strip a { display: block; }
.birthday-strip .mat {
  display: grid;
  place-items: center;
  width: clamp(5.5rem, 22vw, 7.5rem);
  aspect-ratio: 1;
  padding: 0.35rem;
  background: #fff;
  box-shadow: var(--mat-shadow);
}
.birthday-strip img { max-width: 100%; max-height: 100%; object-fit: contain; }
.birthday-strip-label { margin: 0 0 0.75rem; font-size: 0.85rem; }
.birthday-links { display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; margin: 0; }
.birthday-links a { display: inline-flex; align-items: center; gap: 0.35rem; min-height: 2.75rem; }
.birthday-links .icon { width: 1rem; height: 1rem; }

/* The cake beside a name, on the day, in a room's labels and chips. */
.birthday-cake { display: inline-flex; vertical-align: -0.12em; margin-inline-start: 0.25rem; }
.birthday-cake .icon { width: 1em; height: 1em; }
