:root {
  color-scheme: dark;
  font-family: var(--body-type);
  --night: #090706;
  --ivory: #fff2dc;
  --gold: #f5cb86;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; color: var(--ivory); background: var(--night); }
p, h1 { margin: 0; }
.entrance {
  position: relative;
  isolation: isolate;
  height: 100svh;
  height: 100dvh;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: minmax(0, 36.75rem) auto auto;
  align-content: center;
  justify-items: center;
  overflow: clip;
  text-align: center;
  padding: max(3.4rem, calc(env(safe-area-inset-top) + 3rem)) 1rem max(1.4rem, env(safe-area-inset-bottom));
  background:
    radial-gradient(ellipse at 50% 38%, #3e24117d, transparent 64%),
    linear-gradient(180deg, #100a06, #090706 25%, #090706 100%);
}
.entrance .account-area {
  position: absolute;
  z-index: 2;
  inset-block-start: max(0.55rem, env(safe-area-inset-top));
  inset-inline-start: max(1rem, env(safe-area-inset-left));
}
.entrance .account-button:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }

.identity, .invitation { position: relative; z-index: 1; min-inline-size: 0; max-inline-size: 100%; }
.identity {
  inline-size: min(92%, 36rem);
  margin-bottom: clamp(1.15rem, 3.4dvh, 2.25rem);
  font-size: clamp(2rem, 5.1vw, 4.65rem);
  -webkit-text-size-adjust: none;
  text-size-adjust: none;
}
.brand {
  display: block;
  inline-size: 100%;
  block-size: auto;
}
.brand text { font: 700 88px var(--brand-type); }
.signature {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(0.38rem, 1.7vw, 0.75rem);
  margin-bottom: 0.34rem;
  font: 400 clamp(0.77rem, 0.32em, 1.25rem)/1.2 var(--body-type);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: #f2d09a;
}
.signature::before, .signature::after {
  content: '';
  display: block;
  width: clamp(1.1rem, 0.76em + 2vw, 3rem);
  height: 1px;
  background: linear-gradient(90deg, #967047, #f3cc88);
}
.signature::after { transform: scaleX(-1); }
.experience {
  margin-top: 0.36rem;
  padding-left: 0.43em;
  font: 400 clamp(0.81rem, 0.39em, 1.45rem)/1.1 var(--body-type);
  letter-spacing: 0.43em;
  text-transform: uppercase;
  color: #e9c990;
}
.stage {
  position: relative;
  display: grid;
  place-items: center;
  width: min(100%, 56rem);
  min-height: 0;
  isolation: isolate;
}
.stage-glow, .stage-reflection { position: absolute; pointer-events: none; }
.stage-glow {
  inset: 5% -12% 2%;
  background:
    radial-gradient(ellipse at 37% 47%, #051eb844, transparent 26%),
    radial-gradient(ellipse at 63% 49%, #dc251a36, transparent 26%),
    radial-gradient(ellipse at 52% 68%, #3cc30730, transparent 29%),
    radial-gradient(ellipse at 50% 48%, #d187333e, transparent 58%);
  filter: blur(2.1rem);
}
.bottle-frame {
  position: absolute;
  inset-block: auto 0;
  aspect-ratio: 8 / 11;
  max-width: 100%;
  height: 100%;
  z-index: 1;
}
.bottle {
  display: block;
  height: 100%;
  width: 100%;
}
.bottle-liquid {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  visibility: hidden;
}
.bottle-liquid.is-ready { visibility: visible; }
.ribbons { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.blue { --light: #164dff; --core: #119dff; }
.red { --light: #ff2100; --core: #ff6617; }
.green { --light: #42e700; --core: #a7ff31; }
.ribbon-back { stroke: var(--light); stroke-width: 4.5; opacity: 0.78; filter: drop-shadow(0 0 6px var(--light)); }
.ribbon-glow { stroke: var(--light); stroke-width: 9; filter: drop-shadow(0 0 5px var(--light)) drop-shadow(0 0 11px var(--light)) drop-shadow(0 0 17px var(--light)); }
.ribbon-core { stroke: var(--core); stroke-width: 3.5; }
.liquid-ignition, .prism-glint, .gold-glints path { opacity: 0; }
.gold-glints { fill: none; stroke: #fff1bd; stroke-width: 3; stroke-linecap: round; filter: drop-shadow(0 0 6px #ffbc56); }
.gold-glints path { stroke-dasharray: 0.19 1; }
.cap-glint { stroke-width: 3.5; }
.is-animating .rise-curtain { animation: liquid-rise 2.45s cubic-bezier(0.25, 0.47, 0.3, 1) both; }
.is-animating .liquid-ignition { animation: liquid-ignition 1.65s ease-out 0.1s both; }
.is-animating .prism-glint { animation: prism-glint 0.95s ease-in-out 1.25s both; }
.is-animating .cap-glint { animation: gold-glint 0.72s ease-in-out 0.08s both; }
.is-animating .rim-glint { animation: gold-glint 1.55s ease-in-out 0.32s both; }

@keyframes liquid-rise {
  0% { transform: translateY(642px); }
  100% { transform: translateY(101px); }
}
@keyframes liquid-ignition {
  0% { opacity: 0; }
  35% { opacity: 0.7; }
  100% { opacity: 0; }
}
@keyframes prism-glint {
  0%, 100% { opacity: 0; }
  44% { opacity: 0.52; }
}
@keyframes gold-glint {
  0% { stroke-dashoffset: 0.19; opacity: 0; }
  24% { opacity: 0.9; }
  76% { opacity: 0.84; }
  100% { stroke-dashoffset: -1; opacity: 0; }
}
.stage-reflection {
  inset: auto 16% 7% 16%;
  height: 9%;
  border-radius: 50%;
  background: radial-gradient(ellipse, #ffd0839c, #c371296e 29%, transparent 69%);
  filter: blur(0.55rem);
}
.invitation { display: grid; justify-items: center; gap: clamp(0.8rem, 2.1svh, 1.4rem); }
h1 {
  max-width: 19ch;
  font: italic 400 clamp(2.3rem, 4.8vw, 4.2rem)/0.93 var(--display);
  letter-spacing: 0.025em;
  text-transform: uppercase;
  text-wrap: balance;
  overflow-wrap: anywhere;
}
h1 em { display: block; color: var(--gold); }
.enter {
  position: relative;
  display: inline-grid;
  place-items: center;
  min-height: 3.55rem;
  min-width: min(100%, 12rem);
  padding: 0.55rem 1.6rem;
  background: linear-gradient(115deg, #ffe6b7 5%, #d6a055 100%);
  color: #211306;
  border: 1px solid #ffda99;
  box-shadow: 0 0 1.5rem #d9934657, inset 0 0 0 3px #7f4b1b2e;
  text-decoration: none;
  font: 600 1.125rem/1.15 var(--body-type);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  transition: box-shadow 180ms ease, background-color 180ms ease;
}
.enter:hover { box-shadow: 0 0 2.2rem #ffc373a0, inset 0 0 0 3px #7f4b1b39; }
.enter:focus-visible { outline: 3px solid #fff1cf; outline-offset: 5px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

@media (max-width: 550px) {
  .entrance {
    grid-template-rows: minmax(0, min(82vw, 20.5rem)) auto auto;
    padding-block-end: max(1rem, env(safe-area-inset-bottom));
  }
  .stage-glow { filter: blur(1.35rem); }
  .identity { font-size: clamp(1.92rem, 10.6vw, 3.7rem); }
  .signature { font-size: min(clamp(0.77rem, 0.32em, 1.25rem), 3.8vw); }
  .invitation { gap: 0.65rem; }
  h1 { max-width: none; font-size: clamp(1.85rem, 7.8vw, 2.65rem); }
  .enter { min-height: 3.15rem; }
}
@media (max-height: 480px) {
  .entrance { padding-block-end: 0.5rem; }
  .identity { margin-bottom: 0.85rem; }
  .invitation { gap: 0.45rem; }
  h1 { font-size: min(7.3dvh, 1.9rem); }
}
@media (prefers-reduced-motion: reduce) {
  .is-animating :is(.rise-curtain, .liquid-ignition, .prism-glint, .gold-glints path) { animation: none; }
  .enter { transition: none; }
}
