/* One uniform layout scale preserves the supplied PNGs and their overlap. */
.keyboard-entry {
  position: fixed;
  left: -200vw;
}
.keyboard-entry:focus-visible {
  left: 50%;
  top: 18px;
  transform: translateX(-50%);
  padding: 9px 18px;
}
#profile {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  overflow: hidden;
  background: transparent;
  color: #573b28;
}
#profile::backdrop {
  background: rgb(55 39 27 / 10%);
  backdrop-filter: blur(13px);
  -webkit-backdrop-filter: blur(13px);
}
#profile[open] {
  animation: profile-appear 320ms ease-out;
}
#profile[open]::backdrop {
  animation: backdrop-appear 320ms ease-out;
}
#profile-close {
  position: absolute;
  z-index: 20;
  top: max(18px, env(safe-area-inset-top));
  left: max(18px, env(safe-area-inset-left));
  padding: 8px 16px;
}
.profile-stage {
  position: absolute;
  inset: 64px 0 20px;
  pointer-events: none;
}
.profile-layout {
  position: absolute;
  left: 50%;
  top: 50%;
  width: var(--layout-width, 920px);
  height: 920px;
  transform: translate(-50%, -50%) scale(var(--profile-scale, 1));
  transform-origin: center;
  isolation: isolate;
  pointer-events: none;
}
.profile-piece {
  position: absolute;
  display: block;
  width: auto;
  height: auto;
  margin: 0;
  padding: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  transform-origin: 50% 50%;
  transition: transform 340ms cubic-bezier(.22, .7, .25, 1), filter 340ms ease;
  pointer-events: auto;
  -webkit-tap-highlight-color: transparent;
  touch-action: pinch-zoom;
}
.profile-piece img {
  display: block;
  width: 100%;
  height: auto;
  max-width: none;
  user-select: none;
  -webkit-user-select: none;
}
.resume-piece {
  z-index: 1;
  top: 38px;
  left: var(--resume-left, 285px);
  width: 580px;
  transform: translateY(0) scale(1);
  filter: drop-shadow(0 6px 9px rgb(55 31 16 / 15%)) drop-shadow(0 22px 30px rgb(55 31 16 / 14%));
}
.card-piece {
  z-index: 2;
  top: 135px;
  left: var(--card-left, 125px);
  width: var(--card-width, 355px);
  transform: rotate(-11deg) scale(1);
  filter: drop-shadow(0 9px 8px rgb(55 31 16 / 21%)) drop-shadow(0 25px 20px rgb(55 31 16 / 12%));
}
.profile-layout[data-front="resume"] .resume-piece,
.profile-layout[data-front="card"] .card-piece {
  z-index: 3;
}
.profile-layout[data-active="resume"] .resume-piece {
  transform: translateY(-5px) scale(1.055);
  filter: drop-shadow(0 14px 15px rgb(55 31 16 / 16%)) drop-shadow(0 32px 34px rgb(55 31 16 / 19%));
}
.profile-layout[data-active="card"] .card-piece {
  transform: translateY(-7px) rotate(-9deg) scale(1.075);
  filter: drop-shadow(0 15px 10px rgb(55 31 16 / 20%)) drop-shadow(0 31px 25px rgb(55 31 16 / 16%));
}
@media (min-width: 700px) and (hover: hover) and (pointer: fine) {
  .profile-layout[data-active="resume"] .resume-piece {
    transform: translateY(-5px) scale(1.18);
  }
  .profile-layout[data-active="card"] .card-piece {
    transform: translateY(-7px) rotate(-9deg) scale(1.25);
  }
}
.profile-piece:focus-visible {
  outline: 2px solid #71553b;
  outline-offset: 10px;
}
@keyframes profile-appear {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes backdrop-appear {
  from { background: transparent; backdrop-filter: blur(0); }
  to { background: rgb(55 39 27 / 10%); backdrop-filter: blur(13px); }
}
@media (prefers-reduced-motion: reduce) {
  #profile[open], #profile[open]::backdrop { animation: none; }
  .profile-piece { transition: none; }
}

