/* The booth is a self-contained illustrative print demo. */
.booth-live {
  --booth-metal: #38362f;
  --booth-rim: #565247;
  width: 100%;
  max-width: 430px;
  min-width: 0;
  justify-self: center;
  position: relative;
  padding: 28px 16px 0;
  isolation: isolate;
}

.booth-live::before {
  content: '';
  position: absolute;
  inset: 0 -15% 12%;
  z-index: -1;
  background: radial-gradient(ellipse at 50% 35%, #d39b5929, transparent 66%);
  pointer-events: none;
}

.booth-live-note {
  position: absolute;
  top: -8px;
  right: 8px;
  color: #e8bb96;
  font-size: 26px;
  rotate: 6deg;
}

.booth-machine {
  position: relative;
  z-index: 2;
  max-width: 360px;
  margin: 0 auto;
  padding: 17px 19px 22px;
  border: 1px solid #716b5f;
  border-bottom-color: #191814;
  border-radius: 24px;
  background: linear-gradient(145deg, #4a473e, #302e28 58%, #3a372f);
  box-shadow: inset 0 1px 0 #aca08f4a, 0 25px 45px #0e0d0a42;
}

.booth-machine-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 13px;
}

.booth-machine-wordmark {
  font-family: var(--display);
  font-size: 25px;
  letter-spacing: -1px;
  line-height: 1;
  color: #f7eddb;
}

.booth-machine-wordmark i {
  color: var(--coral);
  font-style: normal;
}

.booth-machine-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 7px;
  letter-spacing: 1.3px;
  color: #cac3b6;
}

.booth-machine-live::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #debd86;
  box-shadow: 0 0 8px #debd8659;
}

.booth-viewfinder {
  aspect-ratio: 1.75;
  position: relative;
  overflow: hidden;
  border: 4px solid #14130f;
  border-radius: 11px;
  background: #14130f;
  box-shadow: 0 1px 0 #8f857e55;
}

.booth-viewfinder img {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  object-fit: cover;
  object-position: 50% 37%;
  opacity: 0;
  transition: opacity .24s ease;
}

.booth-viewfinder img:first-child,
.booth-live[data-pose='0'] .booth-viewfinder img:nth-child(1),
.booth-live[data-pose='1'] .booth-viewfinder img:nth-child(2),
.booth-live[data-pose='2'] .booth-viewfinder img:nth-child(3) {
  opacity: 1;
}

.booth-live[data-pose='1'] .booth-viewfinder img:first-child,
.booth-live[data-pose='2'] .booth-viewfinder img:first-child {
  opacity: 0;
}

.booth-viewfinder::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(#0003, transparent 36%, #0005);
  pointer-events: none;
}

.booth-screen-top,
.booth-screen-bottom {
  position: absolute;
  z-index: 2;
  left: 10px;
  right: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #fff9ed;
  font-size: 6px;
  font-weight: 500;
  letter-spacing: 1.4px;
  text-shadow: 0 1px 5px #0008;
}

.booth-screen-top { top: 9px; }
.booth-screen-bottom { bottom: 9px; }

.booth-capture-mark {
  width: 6px;
  height: 6px;
  border: 1px solid currentColor;
  border-radius: 50%;
}

.booth-countdown {
  position: absolute;
  z-index: 3;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: var(--display);
  font-size: 78px;
  line-height: 1;
  color: #fffaef;
  text-shadow: 0 4px 30px #241b1670;
  opacity: 0;
  pointer-events: none;
}

.booth-live[data-phase='capture'] .booth-countdown { opacity: 1; }

.booth-viewfinder-flash {
  position: absolute;
  z-index: 4;
  inset: 0;
  background: #fffaef;
  opacity: var(--booth-flash, 0);
  pointer-events: none;
}

.booth-machine-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 14px;
  font-size: 6px;
  line-height: 1.5;
  letter-spacing: 1.6px;
  color: #ccc1ae;
}

.booth-speaker {
  width: 40px;
  height: 13px;
  background: repeating-linear-gradient(90deg, #14130f 0 2px, transparent 2px 5px);
  opacity: .6;
}

.booth-print-mouth {
  position: absolute;
  z-index: 4;
  bottom: -4px;
  left: 15%;
  right: 15%;
  height: 15px;
  border: 3px solid #605b4e;
  border-top-width: 4px;
  border-radius: 6px;
  background: #0f0f0c;
  box-shadow: 0 3px 0 #15140f, inset 0 2px 3px #000;
}

.booth-print-window {
  position: relative;
  z-index: 1;
  height: 375px;
  max-width: 360px;
  overflow: hidden;
  margin: -1px auto 0;
  padding-top: 0;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}

.booth-print-window::before {
  content: '';
  position: absolute;
  z-index: 3;
  top: 0;
  left: 18%;
  right: 18%;
  height: 24px;
  background: linear-gradient(#0006, transparent);
  pointer-events: none;
}

.booth-paper {
  --strip-paper: #f7f1e6;
  width: clamp(142px, 52%, 184px);
  padding: 13px 11px 12px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  background: var(--strip-paper);
  color: #35281e;
  box-shadow: 4px 11px 13px #0004;
  transform: translateY(var(--booth-feed, 0%));
  transform-origin: 50% 10%;
  rotate: 0deg;
  transition: background .25s ease, rotate .6s ease;
  will-change: auto;
}

.booth-live[data-phase='printing'] .booth-paper { will-change: transform; }
.booth-live[data-phase='done'] .booth-paper { rotate: -3deg; }

.booth-paper img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1.8;
  object-fit: cover;
  object-position: 50% 37%;
  border: 1px solid #45342512;
}

.booth-viewfinder img:nth-child(3),
.booth-paper img:nth-child(3) { object-position: 50% 16%; }

.booth-paper-caption {
  font-size: 19px;
  line-height: 1.15;
  padding: 5px 0 1px;
  text-align: center;
  white-space: nowrap;
}

.booth-paper-brand {
  padding-top: 3px;
  text-align: center;
  font-size: 5px;
  line-height: 1.5;
  letter-spacing: 1.4px;
}

.booth-live-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid #b8a48c26;
  padding-top: 15px;
}

.booth-live-label {
  color: #b9af9f;
  font-size: 7px;
  line-height: 1.8;
  letter-spacing: 1.2px;
}

.booth-live-label > span {
  display: block;
  color: #e8cfac;
  font-size: 10px;
  letter-spacing: .1px;
}

.booth-replay {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  border: 1px solid #b8a48c4d;
  border-radius: 99px;
  padding: 0 14px;
  font: inherit;
  font-size: 9px;
  color: #f7ecdb;
  background: #ffffff04;
  white-space: nowrap;
  cursor: pointer;
  transition: border-color .2s, background .2s;
}

.booth-replay svg { width: 12px; height: 12px; }
.booth-replay:hover { border-color: #e8bb96; background: #e8bb9612; }
.booth-replay:focus-visible { outline: 2px solid #e8bb96; outline-offset: 4px; }
.booth-replay:disabled { opacity: .45; cursor: default; }
.booth-live:not([data-booth-enhanced='true']) .booth-replay { display: none; }
.booth-live[data-reduced='true'] .booth-replay { display: none; }

@media (max-width: 1000px) and (min-width: 761px) {
  .booth-live { padding-inline: 0; }
  .booth-machine { padding: 15px 15px 20px; }
  .booth-print-window { height: 350px; }
  .booth-live-controls { gap: 8px; }
  .booth-live-label { font-size: 6px; }
  .booth-live-label > span { font-size: 9px; }
  .booth-replay { padding-inline: 10px; font-size: 8px; }
}

@media (max-width: 760px) {
  .booth-live { margin-top: 46px; padding-top: 27px; padding-bottom: 18px; max-width: 400px; }
  .booth-print-window { height: 350px; }
  .booth-live-note { font-size: 24px; right: 20px; }
}

@media (max-width: 360px) {
  .booth-live { padding-inline: 0; }
  .booth-machine { padding: 15px 14px 20px; border-radius: 20px; }
  .booth-print-window { height: 325px; }
  .booth-paper-caption { font-size: 17px; }
  .booth-machine-wordmark { font-size: 23px; }
  .booth-live-label { font-size: 6px; }
  .booth-live-label > span { font-size: 9px; }
  .booth-replay { padding-inline: 11px; font-size: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  .booth-live *, .booth-live *::before, .booth-live *::after { transition: none !important; animation: none !important; }
}
