.hero-title__trigger {
  display: block;
  flex: 0 0 auto;
  padding: 0;
  border: 0;
  background: transparent;
  line-height: 0;
  cursor: pointer;
}
.hero-title__trigger:focus-visible {
  outline: 1px solid #c8aa70;
  outline-offset: 12px;
  border-radius: 50%;
}
.hero-title__trigger:hover .hero-title__pattern {
  filter: brightness(1.12);
}
body.stitch-transition-lock { overflow: hidden; }
.cloth-transition[hidden] { display: none; }
.cloth-transition {
  position: fixed;
  inset: 0;
  z-index: 20000;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(5, 4, 3, .97);
  opacity: 0;
  transition: opacity .65s ease;
}
.cloth-transition.is-visible { opacity: 1; }
.cloth-transition__sheet {
  position: relative;
  width: min(1160px, 100%);
  max-height: calc(100dvh - 48px);
  overflow: auto;
  background: #eee4ce url('./embroidery-cloth.png') center / cover no-repeat;
  border: 1px solid #c1aa80;
  box-shadow: 0 24px 90px #0008;
  transform: translateY(22px) scale(.97);
  transition: transform 1.1s cubic-bezier(.2,.65,.25,1);
}
.is-visible .cloth-transition__sheet { transform: none; }
.cloth-transition__art {
  position: relative;
  z-index: 2;
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}
.cloth-transition__label {
  fill: #80684e;
  font: 25px 'KaiTi', 'STKaiti', serif;
  letter-spacing: 4px;
}
.cloth-transition__skip {
  z-index: 4;
  position: absolute;
  right: 20px;
  bottom: 16px;
  padding: 7px 12px;
  border: 1px solid #a28a64;
  background: #f8efdbde;
  color: #695137;
  font: 13px 'Microsoft YaHei', sans-serif;
  cursor: pointer;
}
.cloth-transition__skip:hover { background: #fff8e9; }
.cloth-transition__skip:focus-visible { outline: 2px solid #862f35; }
.cloth-transition__hint {
  z-index: 4;
  position: absolute;
  left: 20px;
  bottom: 23px;
  color: #897356;
  font: 12px 'KaiTi', serif;
  letter-spacing: 2px;
}
.cloth-transition__thread {
  fill: none;
  stroke: #943c3a;
  stroke-width: 1.1;
  stroke-linecap: round;
}
.cloth-transition__fallback {
  fill: #862f35;
  font: 52px 'KaiTi', 'STKaiti', serif;
  text-anchor: middle;
}
.cloth-transition__english-fallback {
  fill: #705039;
  font: italic 26px Georgia, serif;
  text-anchor: middle;
}
.soft-thread {
  fill: none;
  stroke: #9c5044;
  stroke-width: 2.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.soft-thread--shadow {
  stroke: #694c39;
  stroke-width: 3.8;
  opacity: .18;
  transform: translate(1px, 2px);
}
.soft-thread--light {
  stroke: #e3ad88;
  stroke-width: .65;
  opacity: .9;
  transform: translate(-.55px, -.4px);
}
.cloth-bird {
  position: absolute;
  z-index: 1;
  width: 22%;
  height: auto;
  pointer-events: none;
  transform-origin: 50% 60%;
  animation-play-state: paused;
}
.is-visible .cloth-bird { animation-play-state: running; }
.cloth-bird--left {
  top: 2%;
  left: 2%;
  animation: clothBirdLeft 5.8s ease-in-out infinite;
}
.cloth-bird--right {
  right: 1%;
  bottom: 13%;
  animation: clothBirdRight 6.8s ease-in-out infinite;
}
@keyframes clothBirdLeft {
  0%, 100% { transform: translate(-4px, 4px) rotate(-3deg); }
  50% { transform: translate(6px, -12px) rotate(3.5deg); }
}
@keyframes clothBirdRight {
  0%, 100% { transform: translate(4px, 3px) rotate(3deg); }
  50% { transform: translate(-7px, -14px) rotate(-4deg); }
}
@media (max-width: 600px) {
  .cloth-transition { padding: 14px; }
  .cloth-transition__sheet { max-height: calc(100dvh - 28px); }
  .cloth-transition__hint { display: none; }
  .cloth-transition__skip { right: 12px; bottom: 12px; }
  .cloth-bird { width: 29%; }
  .cloth-bird--right { bottom: 11%; }
}
@media (prefers-reduced-motion: reduce) {
  .cloth-transition, .cloth-transition__sheet { transition: none; }
  .cloth-bird { animation: none; }
}
