/* All geometry is local to the arrival overlay. The storefront is already mounted behind it. */
@property --yi-aperture {
  syntax: '<percentage>';
  inherits: false;
  initial-value: 0%;
}
#yii-optic-entry {
  --yi-horizon: 39.5%;
  --yi-press: 16.4%;
  --yi-art-size: min(72vh, 780px, 87vw);
  --yi-x: 0px; --yi-y: 0px;
  position: fixed; inset: 0; z-index: 100008;
  overflow: hidden; isolation: isolate; contain: layout paint;
  margin: 0; outline: 0; color: #f6e6c8;
  background: #101112;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", sans-serif;
  -webkit-tap-highlight-color: transparent;
}
#yii-optic-entry, #yii-optic-entry * { box-sizing: border-box; }
#yii-optic-entry :is(.yi-optics,.yi-tableau) { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
#yii-optic-entry .yi-optics {
  background: radial-gradient(ellipse at 53% 36%,#3c352c 0%,#211f1e 35%,#151618 66%,#0a0c10 100%);
}
#yii-optic-entry .yi-photograph {
  position: absolute; inset: -4%;
  background: url('/assets/yii-atmosphere-c303992174f3.jpg') center / cover;
  filter: grayscale(.85) blur(3px); opacity: .36;
  mask-image: linear-gradient(108deg,#000b,transparent 46%,transparent 58%,#000a);
}
#yii-optic-entry .yi-studio-light {
  position: absolute; inset: -10%; transform-origin: 50% 50%;
  background: radial-gradient(ellipse 40% 21% at 56% 31%,#c2a67c20,transparent),
    linear-gradient(119deg,transparent 12%,#f3dab508 26%,#ffe6ac13 27%,transparent 33% 64%,#abb8bb0b 71%,transparent 78%);
  animation: yi-room 4s cubic-bezier(.14,.52,.27,.99) both;
}
#yii-optic-entry .yi-light-slit {
  position: absolute; left: -18%; top: -42%; width: 155%; height: 85%; border-radius: 50%;
  transform: rotate(-18deg);
  border-bottom: 1px solid #e8cda23b;
  box-shadow: 0 1px 7px #fbe7c116, inset 0 -12px 30px -28px #f6db9f80;
  mask-image: linear-gradient(97deg,transparent 12%,black 33%,#0001 66%,transparent 80%);
  animation: yi-glass-in 1.45s both;
}
#yii-optic-entry .yi-glass-grain {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 45%,transparent 34%,#07080970 100%);
}
#yii-optic-entry .yi-stage {
  width: var(--yi-art-size); height: var(--yi-art-size); position: absolute;
  left: 50%; top: var(--yi-horizon); transform: translate(-50%,-50%);
}
#yii-optic-entry .yi-parallax {
  position: absolute; inset: 0; transform: translate3d(var(--yi-x),var(--yi-y),0);
  transition: transform .32s ease-out;
}
#yii-optic-entry .yi-parallax img {
  display: block; width: 100%; height: 100%; max-width: none; object-fit: contain;
}
#yii-optic-entry .yi-lower, #yii-optic-entry .yi-upper { position: absolute; inset: 0; }
#yii-optic-entry .yi-lower { animation: yi-base 3.4s both; }
#yii-optic-entry .yi-upper { animation: yi-keystroke 3.42s both; }
#yii-optic-entry .yi-caustic, #yii-optic-entry .yi-wave {
  position: absolute; left: 50%; top: 88%; width: 93%; height: 20%;
  transform: translate(-50%, -50%) rotate(-7deg);
  border-radius: 50%; pointer-events: none;
}
#yii-optic-entry .yi-caustic {
  background: radial-gradient(ellipse, #030404ba 5%,#090807a8 17%,#a07a4a38 39%,#cca66b21 50%,transparent 72%);
  filter: blur(9px); animation: yi-pool 3.5s both;
}
#yii-optic-entry .yi-wave {
  border: 1px solid #ffe7b6; box-shadow: 0 0 6px #ffdba58c,inset 0 0 15px #f4cd7114;
  animation: yi-contact .8s 2.54s both;
}
#yii-optic-entry .yi-identity {
  position: absolute; inset-inline: 0; top: 72%; z-index: 1;
  text-align: center; pointer-events: none;
  mix-blend-mode: screen; animation: yi-sign .72s .08s both;
}
#yii-optic-entry .yi-wordmark {
  position: relative; width: clamp(138px,min(24vw,24vh),236px); aspect-ratio: 1160/628;
  overflow: hidden; margin: 0 auto; isolation: isolate;
}
#yii-optic-entry .yi-wordmark img {
  position: absolute; left: -4.57%; top: -55.41%; width: 108.104%; height: auto; max-width: none;
}
#yii-optic-entry .yi-wordmark::after {
  content: ''; position: absolute; inset: 0; pointer-events: none; mix-blend-mode: overlay;
  background: linear-gradient(112deg,transparent 32%,#fff8de 49%,transparent 66%);
  animation: yi-foil 1.6s .2s both;
}
#yii-optic-entry .yi-motto {
  margin: clamp(8px,1.4vh,18px) 0 0; padding-left: .28em;
  font: 400 clamp(13px,1.75vh,19px)/1.45 "Songti SC","STSong","Noto Serif CJK SC",serif;
  letter-spacing: .28em; color: #f1dfbb;
}
#yii-optic-entry .yi-translation {
  margin: .45em 0 0; color: #c2b59f;
  font: italic clamp(10px,1.25vh,14px)/1.4 Georgia,serif; letter-spacing: .015em;
}
#yii-optic-entry .yi-skip {
  position: absolute; bottom: max(24px,env(safe-area-inset-bottom)); right: max(4vw,20px); z-index: 2;
  appearance: none; min-height: 44px; padding: 0 8px; display: inline-flex; align-items:center; gap: 9px;
  border: 0; border-radius: 0; box-shadow: none; background: transparent; color: #e2d6bf;
  font-family: inherit; font-size: 12px; line-height: 1.3; cursor: pointer;
}
#yii-optic-entry .yi-skip[hidden] { display: none; }
#yii-optic-entry .yi-skip span { font-size: 16px; color: #e9c48b; }
#yii-optic-entry .yi-skip:hover { color: white; }
#yii-optic-entry .yi-skip:focus-visible { outline: 1px solid #dfbf8a; outline-offset: 3px; }
#yii-optic-entry.yi-opening {
  mask-image: radial-gradient(ellipse farthest-corner at 50% var(--yi-horizon),transparent max(0%, calc(var(--yi-aperture) - 17%)),#000 var(--yi-aperture));
  animation: yi-lens-open 1.55s cubic-bezier(.51,.02,.19,1) both;
}
#yii-optic-entry.yi-skipping { animation: yi-quick-fade .18s linear both; }
#yii-optic-entry.yi-signature-only .yi-tableau { display: none; }
#yii-optic-entry.yi-signature-only .yi-identity { top: 42%; }
@keyframes yi-base {
  0% { opacity: .32; transform: translateY(4%); }
  25%,73% { opacity: 1; transform: translateY(0); }
  78% { transform: translateY(.85%); }
  89%,100% { transform: translateY(0); opacity: 1; }
}
@keyframes yi-keystroke {
  0% { opacity: .15; transform: translateY(-8%); animation-timing-function: cubic-bezier(.13,.65,.18,1); }
  29% { opacity: 1; transform: translateY(-2.8%); }
  63% { opacity: 1; transform: translateY(-3.7%); animation-timing-function: cubic-bezier(.68,0,1,.5); }
  76% { transform: translateY(var(--yi-press)); animation-timing-function: ease-out; }
  83% { transform: translateY(calc(var(--yi-press) - .9%)); }
  93%,100% { transform: translateY(calc(var(--yi-press) - .4%)); opacity: 1; }
}
@keyframes yi-pool {
  0% { opacity: .24; } 34%,68% { opacity:.62; } 76% { opacity:1; } 100% { opacity:.75; }
}
@keyframes yi-contact {
  0% { opacity:0; transform:translate(-50%,-50%) rotate(-7deg) scale(.28); }
  14% { opacity:.72; }
  100% { opacity:0; transform:translate(-50%,-50%) rotate(-7deg) scale(1.45); }
}
@keyframes yi-room { from { opacity:.4; transform:translateX(-3%); } to { opacity:1; transform:translateX(1%); } }
@keyframes yi-glass-in { from { opacity: 0; } to { opacity:1; } }
@keyframes yi-sign { from { opacity:.1; } to { opacity:1; } }
@keyframes yi-foil { 0% { transform:translateX(-95%); } 100% { transform:translateX(95%); } }
@keyframes yi-lens-open { 0% { --yi-aperture: 0%; opacity:1; } 72% { opacity:.97; } 100% { --yi-aperture:119%; opacity:0; } }
@keyframes yi-quick-fade { to { opacity:0; } }
@media (max-width:650px) and (orientation:portrait) {
  #yii-optic-entry { --yi-art-size: min(125vw,65svh); --yi-horizon:40.8%; }
  #yii-optic-entry .yi-identity { top:70%; }
  #yii-optic-entry .yi-wordmark { width:clamp(150px,43vw,210px); }
  #yii-optic-entry .yi-motto { font-size:15px; }
  #yii-optic-entry .yi-translation { font-size:11px; }
  #yii-optic-entry .yi-light-slit { width:270%; left:-83%; top:-46%; }
  #yii-optic-entry .yi-skip { bottom:max(17px,env(safe-area-inset-bottom)); right:5vw; }
}
@media (max-height:550px) and (orientation:landscape) {
  #yii-optic-entry { --yi-horizon:48%; --yi-art-size:94vh; }
  #yii-optic-entry .yi-tableau { left:34%; }
  #yii-optic-entry .yi-identity { width:40%; top:34%; left:5%; }
  #yii-optic-entry .yi-wordmark { width:24vh; }
}
@media (prefers-reduced-motion:reduce) {
  #yii-optic-entry *, #yii-optic-entry *::after { animation:none!important; transition:none!important; }
  #yii-optic-entry .yi-wave,#yii-optic-entry .yi-wordmark::after { display:none; }
  #yii-optic-entry .yi-upper { transform:translateY(var(--yi-press)); }
  #yii-optic-entry.yi-opening { mask-image:none; animation:yi-quick-fade .18s linear both; }
}
