#view-windows .ground { gap: 10px; }
#status:empty { display: none; }
#foot { margin-bottom: 12px; }
#task-setup .setup-header .close { margin-left: 0; }
#task-setup .setup-guide { font-size: clamp(15px, 2.4vw, 18px); }
#intro .instruction-toggle { gap: 10px; }
.instruction-icon {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border: 1px solid #ffe8ad;
  border-radius: 50%;
  font: bold 20px/1 system-ui, sans-serif;
}
.garland2 .bulb, .garland2 .bulb:nth-child(n) {
  animation: garland-glow 2.5s linear infinite;
  animation-delay: calc(var(--phase) * 0.5s - 2.5s);
}
@keyframes garland-glow {
  0%, 36%, 100% { opacity: .43; filter: none; }
  12%, 19% { opacity: 1; filter: drop-shadow(0 0 4px #ffc969); }
}
.advent-projects { width: min(100%, 620px); }
.project-gallery > summary { cursor: pointer; list-style: none; }
.project-gallery > summary::-webkit-details-marker { display: none; }
.project-gallery > summary {
  flex-direction: column;
  row-gap: 4px;
  padding-bottom: 9px;
}
.project-gallery > summary::after {
  content: '＋';
  display: block;
  position: static;
  border: 0;
  opacity: 1;
  font: 700 19px/1 system-ui, sans-serif;
}
.project-gallery[open] > summary::after { content: '−'; }
.project-gallery > a { margin-top: 12px; }
.project-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.project-grid figure {
  margin: 0;
  overflow: hidden;
  border-radius: 10px;
  background: #fff9ee;
  border: 1px solid #ddc5a0;
}
.project-grid img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; }
.project-grid figcaption { padding: 8px; line-height: 1.25; overflow-wrap: break-word; }
.film-age-note { margin: 12px 0 0; }
#opening .card-top { display: flex; }
.opening-starter {
  display: grid;
  justify-items: center;
  gap: 12px;
  text-align: center;
  padding: 12px 6px 20px;
}
.opening-starter[hidden] { display: none; }
.opening-starter p { margin: 0; font-weight: 700; }
.game-shutters {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  width: min(256px, 72vw);
  aspect-ratio: 1.22;
  overflow: hidden;
  border: 1px solid #a67a42;
  border-radius: 24px;
  background: #fff9ee;
  padding: 5px;
  box-shadow: 0 10px 36px #593c2226;
}
.game-shutters > span {
  position: relative;
  background: repeating-linear-gradient(90deg, transparent 0 37px, #184837 38px 39px),
    linear-gradient(135deg, #356951, #1c4e3e);
}
.game-shutters > span:first-child { border-radius: 19px 6px 6px 19px; }
.game-shutters > span:nth-child(2) { border-radius: 6px 19px 19px 6px; }
.game-shutters > span::after {
  content: "";
  position: absolute;
  inset: 12px;
  border: 1px solid #c9ad74;
  border-radius: 12px;
}
.game-shutters > i {
  position: absolute;
  top: 50%;
  left: 50%;
  translate: -50% -50%;
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border: 3px double #e4c391;
  border-radius: 50%;
  background: #891925;
  color: #fff7dc;
  box-shadow: 0 5px 14px #40181065;
  font: 26px/1 Georgia, serif;
}
@media (max-width: 520px) {
  .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 350px) {
  #task-setup .setup-header { gap: 7px; }
  #task-setup .setup-header .close { padding-inline: 8px; }
  .tree-history-link { max-width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .garland2 .bulb, .garland2 .bulb:nth-child(n) { animation: none; }
}
#check .check-film-link {
  display: inline-block;
  margin: 0 12px 8px 35px;
  color: var(--green);
  text-underline-offset: 3px;
}

#intro .instruction-toggle {
  color: #fff9ee;
  background: #265641;
  border-color: #9d7a42;
}
.instruction-arrow {
  display: block;
  position: relative;
  width: 18px;
  height: 23px;
  border-right: 2px solid #a57b3d;
  border-radius: 0 45% 45% 0;
  margin: -6px auto 2px;
  transform: translateX(-8px) rotate(-8deg);
}
.instruction-arrow::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 8px;
  right: -4px;
  bottom: 0;
  border: solid #a57b3d;
  border-width: 0 2px 2px 0;
  transform: rotate(54deg);
}
.opening-trigger {
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 0;
  border: 0;
  background: transparent;
  font: inherit;
  cursor: pointer;
}
.opening-trigger:focus-visible { outline: 2px solid #9d7a42; outline-offset: 4px; }

#intro {
  width: min(1120px, 100%);
  padding: 0;
}
#intro .card { padding: clamp(6px, 2vw, 22px); }
#intro .greeting-screen { width: 100%; }
#intro .greeting-screen video { height: auto; max-height: 72dvh; object-fit: contain; }

#opening:has(.opening-starter:not([hidden])) {
  width: 100vw;
  max-width: 100vw;
  max-height: 100dvh;
  border-radius: 0;
}
#opening:has(.opening-starter:not([hidden])) #opening-content { display: none; }
#opening .opening-starter:not([hidden]) {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: clamp(8px, 2vw, 20px);
  overflow: auto;
}
#opening .opening-starter p { order: -1; }
.opening-trigger {
  flex: 1;
  min-height: 0;
  width: 100%;
  grid-template-rows: minmax(168px, 1fr) auto;
}
.opening-trigger .game-shutters {
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  border-radius: 18px;
}
.game-shutters > i.shutter-bow {
  width: clamp(84px, 20vw, 160px);
  height: clamp(48px, 12vw, 90px);
  display: block;
  background: none;
  box-shadow: none;
  border: 0;
  isolation: isolate;
}
.shutter-bow::before, .shutter-bow::after {
  content: "";
  position: absolute;
  inset: 2% 49% 25% 0;
  transform: rotate(14deg);
  border-radius: 45% 24% 24% 46%;
  background: linear-gradient(145deg,#f39582,#ac2438 59%,#671325);
  box-shadow: inset 0 0 0 2px #ffd09777;
}
.shutter-bow::after {
  inset: 2% 0 25% 49%;
  transform: rotate(-14deg);
  border-radius: 24% 45% 46% 24%;
}
.shutter-bow b {
  position: absolute;
  z-index: 1;
  inset: 24% 41% 40%;
  border-radius: 28%;
  background: linear-gradient(#e2545b,#941a31);
  box-shadow: 0 1px 5px #47131a88;
}
.shutter-bow b::before, .shutter-bow b::after {
  content: "";
  position: absolute;
  z-index: -1;
  top: 78%;
  left: -50%;
  width: 105%;
  height: 190%;
  transform: rotate(21deg);
  background: linear-gradient(90deg,#9a1e36,#db5461);
  clip-path: polygon(0 0,100% 0,100% 100%,50% 78%,0 100%);
}
.shutter-bow b::after { left: 48%; transform: rotate(-21deg); }
.project-grid .project-website img { object-fit: contain; background: #f2ede3; }
dialog.af-doc { padding: 0; background: #fff9ee; }
dialog.af-doc .card-top {
  position: static;
  background: transparent;
}
