html.advent-overlay-document, body.advent-embedded { background: transparent }
.advent-embedded .atelier {
  box-sizing: border-box;
  min-height: 100dvh;
  max-width: 1600px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 6px;
  color: #fff5df;
}
.atelier #world[hidden] { display: none }
.advent-embedded .stage {
  isolation: isolate;
  height: min(100dvh, 900px);
  min-height: 0;
  max-height: none;
  margin: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}
.advent-embedded .stage::before {
  content: '';
  position: absolute;
  inset: 2% 0;
  background: radial-gradient(ellipse at 50% 55%, #f3d3a248 0%, #d4bd9220 32%, transparent 68%);
  pointer-events: none;
}
#ambientCanvas.advent-snow-layer { position: fixed }
.advent-embedded #world { position: absolute; inset: 0; width: 100%; height: 100% }
.advent-embedded #world.is-clickable:not(:active) { cursor: pointer }
.advent-embedded #loading { color: #fff5df; background: transparent; pointer-events: none }
.advent-embedded #loading:has(.fallback-scene) { pointer-events: auto }
.advent-embedded :is(.view-tools, .stage-bottom, .experience-controls, .interaction-tip, .advent-scene-options) { display: none }
.advent-embedded :is(.scene-hint, .scene-status),
.advent-embedded .accessible:not(:focus-within) {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.advent-embedded .accessible:focus-within {
  position: fixed;
  inset: auto 10px 10px;
  max-height: 60dvh;
  margin: auto;
  padding: 14px;
  overflow: auto;
  border-radius: 12px;
  background: #142e26;
  color: #fff5df;
  z-index: 6;
}
.advent-embedded:has(.fallback-scene) .atelier { gap: 14px; min-height: 100dvh }
.advent-embedded:has(.fallback-scene) .stage { height: min(65dvh, 560px) }
.advent-embedded .fallback-scene { min-height: 0; background: transparent }
.advent-embedded .fallback-scene :is(.fallback-label, p, .fallback-tree span) { display: none }
.advent-embedded:has(.fallback-scene) .accessible {
  position: relative;
  inset: auto;
  width: auto;
  height: auto;
  max-height: none;
  margin: 0 auto 16px;
  overflow: visible;
  clip-path: none;
  white-space: normal;
  color: #fff5df;
}
.atelier .scene-hint, .atelier .interaction-tip { font-size: 13px }
.atelier .accessible #giftButtons { list-style: none; padding: 0; grid-template-columns: repeat(6, minmax(0, 1fr)) }
.atelier #giftButtons > li { min-width: 0 }
.atelier #giftButtons :is(button, .advent-locked) { display: grid; width: 100%; min-height: 44px; place-items: center; padding: 2px }
.advent-locked { color: #607262; background: #eae6d9; border-radius: 3px }
.atelier .experience-controls button:disabled { opacity: .65; cursor: default }
#gift {
  width: min(576px, calc(100% - 32px));
  max-width: none;
  max-height: calc(100dvh - 32px);
  overflow: auto;
  overscroll-behavior: contain;
  background: #f6f0e1;
  border-color: #bea677;
  text-align: center;
  padding: 0 clamp(20px, 6vw, 42px) clamp(20px, 4dvh, 32px);
}
#gift:has(.advent-video, .advent-article) { width: min(720px, calc(100% - 32px)) }
#gift .close {
  position: sticky;
  top: 10px;
  right: auto;
  margin: 8px calc(-1 * clamp(12px, 4vw, 30px)) -44px auto;
  display: grid;
  width: 44px;
  height: 44px;
  padding: 0;
  place-items: center;
  border-radius: 50%;
  background: #f6f0e1;
  color: #375a49;
  cursor: pointer;
}
#gift .close::before, #gift .close::after {
  content: '';
  grid-area: 1 / 1;
  width: 17px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}
#gift .close::before { transform: rotate(45deg) }
#gift .close::after { transform: rotate(-45deg) }
#gift .close:hover { background: #eae1ca }
#gift .advent-card-header { padding-top: clamp(33px, 6dvh, 48px) }
#giftDay {
  margin: 0;
  color: #746344;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  outline: none;
}
.advent-card-art {
  display: grid;
  place-items: center;
  height: clamp(106px, 22dvh, 194px);
  margin-block: 4px 9px;
  background: radial-gradient(ellipse at center, #d9c99399 0%, transparent 65%);
}
.advent-card-tree {
  position: relative;
  width: clamp(66px, 13dvh, 96px);
  aspect-ratio: 2 / 3;
  background: linear-gradient(#8f693e, #8f693e) center 100% / 12% 14% no-repeat;
  filter: drop-shadow(0 7px 6px #614d3733);
}
.advent-card-tree::before, .advent-card-tree::after { content: ''; position: absolute }
.advent-card-tree::before {
  inset: 0 34% auto;
  aspect-ratio: 1;
  background: #ba903e;
  clip-path: polygon(50% 0%, 61% 34%, 98% 37%, 69% 60%, 79% 96%, 50% 74%, 21% 96%, 31% 60%, 2% 37%, 39% 34%);
}
.advent-card-tree::after {
  inset: 17% 0 9%;
  background:
    radial-gradient(circle at 40% 30%, #e3ba66 0 3%, transparent 3.9%),
    radial-gradient(circle at 64% 62%, #bc6754 0 4%, transparent 4.7%),
    radial-gradient(circle at 32% 83%, #dfbc71 0 3%, transparent 3.8%),
    radial-gradient(circle at 60% 91%, #e1b34e 0 3%, transparent 3.8%),
    linear-gradient(165deg, transparent 75%, #d7b76c 75.5% 76%, transparent 76.5%),
    linear-gradient(23deg, transparent 18%, #d7b76c 18.5% 19%, transparent 19.5% 57%, #d7b76c 57.5% 58%, transparent 58.5%),
    linear-gradient(90deg, #275942 49%, #c5a85e 49.5% 50.5%, #193f31 51%);
  clip-path: polygon(50% 0%, 85% 41%, 72% 41%, 100% 75%, 69% 75%, 94% 100%, 6% 100%, 31% 75%, 0% 75%, 28% 41%, 15% 41%);
}
#gift .advent-gift-content h3 {
  margin: 0 0 clamp(13px, 3.4dvh, 26px);
  font: 600 clamp(31px, 6vw, 45px)/1.04 'Cormorant Garamond', Georgia, serif;
  text-align: center;
  text-wrap: balance;
}
#gift .advent-gift-content ul { gap: 12px }
#gift .advent-gift-content p { color: #52604f; line-height: 1.65 }
#gift .advent-greeting .advent-greeting-phrase {
  max-width: 28ch;
  margin: 0 auto clamp(14px, 3dvh, 24px);
  color: #3e6546;
  font: italic 500 clamp(25px, 5.2vw, 34px)/1.3 'Cormorant Garamond', Georgia, serif;
  text-wrap: balance;
}
#gift :is(.advent-greeting-action, .advent-video) { justify-items: center }
#gift .advent-gift-action { min-height: 48px; padding-inline: 22px; font-size: 14px }
#gift .advent-article { text-align: left }
#gift .advent-code { justify-content: center }
#gift .advent-return {
  min-height: 44px;
  margin-top: 11px;
  padding: 0 10px;
  border: 0;
  background: transparent;
  color: #556659;
  font: 600 13px Manrope, Arial, sans-serif;
  cursor: pointer;
}
#gift .advent-return:hover { text-decoration: underline }
#gift :is(.close, .advent-return):focus-visible { outline: 2px solid #28624f; outline-offset: 2px }
#gift:has(.advent-video, .advent-article) .advent-card-art { height: clamp(95px, 15dvh, 140px) }
#gift:has(.advent-video, .advent-article) .advent-card-tree { width: clamp(55px, 9dvh, 77px) }
@media (max-width: 860px) {
  .advent-embedded #gift {
    inset: 72px 0 12px;
    max-height: calc(100dvh - 84px);
  }
}
@media (max-width: 540px) {
  .atelier .view-tools button { min-height: 40px; min-width: 40px }
}

/* Carry the compartment's soft candlelight into the accessible list. */
.atelier #giftButtons > [aria-current="date"] {
  border-radius: 3px;
  outline: 1px solid #d8b877;
  outline-offset: 2px;
  box-shadow: 0 0 6px #f5d69c80, 0 0 18px #efbf705c, 0 0 32px #eab46629;
}
.atelier #giftButtons > [aria-current="date"] > button {
  background: #fff1cc;
  color: var(--advent-ink);
  font-weight: 700;
}
#gift .advent-sharing { justify-items: center; margin-top: 24px }
#gift .advent-community { text-align: center }
#gift .advent-community-links { justify-content: center }
.advent-embedded .atelier > .advent-sharing {
  position: absolute;
  inset: auto 12px max(16px, env(safe-area-inset-bottom));
  z-index: 2;
  justify-items: center;
  margin: 0;
}
