/* One play destination, one bottom surface. Content scrolls clear of the dock. */
.app-dock {
  display: contents;
}
body.has-play-dock {
  --home-dock-reserve: 140px;
}
body.has-play-dock .app {
  padding-bottom: calc(
    var(--home-dock-reserve) + 36px + var(--safe-bottom, 0px)
  );
}
body.has-play-dock .game-header {
  background: linear-gradient(#f5efdfed, #f5efdfb3);
}
body.has-play-dock .home-hub-hero {
  position: relative;
  padding-bottom: 0;
  transition: none;
}
body.has-play-dock .home-art-window .expedition-art {
  max-width: clamp(600px, calc((100svh - 310px) * 1.96), 1000px);
}
body.has-play-dock .home-hero::before {
  bottom: 0;
}
body.has-play-dock .app-dock {
  position: fixed;
  z-index: 9;
  bottom: max(16px, var(--safe-bottom, env(safe-area-inset-bottom)));
  left: 50%;
  transform: translateX(-50%);
  width: min(1116px, calc(100% - 48px));
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(340px, 1.15fr);
  align-items: center;
  gap: 24px;
  padding: 10px 12px 12px;
  border: 2px solid #bd8b41;
  border-radius: 27px;
  background: linear-gradient(
    155deg,
    #fff7cf,
    #fce5a2 35%,
    #ecc06e 76%,
    #dda05c
  );
  box-shadow:
    inset 0 0 0 2px #fff7d7,
    inset 0 4px 0 #fffced99,
    0 4px 0 #a97637,
    0 12px 24px #5943242b;
}
body.has-play-dock #home-play-slot {
  display: grid;
  gap: 7px;
  min-width: 0;
  padding: 2px 8px;
}
.home-play-context {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  color: #65502d;
}
.home-play-context strong {
  font-size: 12px;
}
.home-play-context span {
  font-size: 10px;
}
body.has-play-dock #start-main {
  width: 100%;
  min-height: 58px;
  position: relative;
  isolation: isolate;
  font-size: 19px;
  border-radius: 19px;
}
body.has-play-dock .app-dock .bottom-nav {
  position: static;
  transform: none;
  inset: auto;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  background: none;
  gap: 7px;
}
body.has-play-dock .app-dock .bottom-nav::before {
  display: none;
}
body.has-play-dock .app-dock .bottom-nav button {
  min-height: 88px;
}
body.has-play-dock .app-dock .bottom-nav .illustrated-icon {
  width: 46px;
  height: 46px;
}
.home-updates {
  position: relative;
  max-width: 1116px;
  margin: 8px auto 28px;
}
.home-updates-heading {
  margin: 0 0 15px;
}
.home-updates-heading > span {
  color: #5b7c6d;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 1.5px;
}
.home-updates-heading h2 {
  margin: 3px 0 0;
  font-size: 26px;
  color: #25494c;
}
.home-updates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr));
  gap: 18px;
}
.home-update-card,
.home-updates .poems-entry {
  width: 100%;
  min-width: 0;
  min-height: 138px;
  margin: 0;
  padding: 14px 20px 14px 10px;
  display: flex;
  align-items: center;
  gap: 18px;
  border: 1px solid #d6c493;
  border-radius: 25px;
  text-align: left;
  color: #294d4e;
  background: linear-gradient(125deg, #fbf5db, #e8efd5 55%, #d8e8db);
  box-shadow:
    inset 0 2px 0 #fffef2,
    0 4px 0 #c6b98c,
    0 8px 14px #67714c12;
}
.home-updates .poems-entry {
  background: linear-gradient(125deg, #faf0dd, #ecdfd3 55%, #dfdfed);
}
.home-update-card > span:last-child {
  display: grid;
  gap: 5px;
}
.home-update-card small,
.home-updates .poems-entry small {
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.8px;
  color: #668276;
}
.home-update-card strong,
.home-updates .poems-entry strong {
  font-size: 21px;
  line-height: 1.15;
}
.home-update-card span > span,
.home-updates .poems-entry span > span {
  font-size: 12px;
  line-height: 1.4;
}
.home-update-card b {
  font-size: 11px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #36756d;
}
.home-update-card b .icon {
  width: 16px;
  height: 16px;
}
.home-update-art {
  position: relative;
  width: 112px;
  height: 106px;
  flex-shrink: 0;
}
.home-update-art img {
  position: absolute;
  width: 98px;
  height: 98px;
  object-fit: contain;
  right: 0;
  top: 0;
}
.home-update-art img:first-child {
  width: 60px;
  height: 60px;
  left: 0;
  top: 45px;
}
.home-updates .poems-entry > img {
  width: 106px;
  height: 106px;
  object-fit: contain;
  flex-shrink: 0;
}
.home-updates .poems-entry > .icon {
  width: 19px;
  height: 19px;
  flex-shrink: 0;
}
body.has-play-dock .home-themes {
  margin-top: 20px;
}
body.has-play-dock .theme-card {
  scroll-margin-block: 96px calc(var(--home-dock-reserve) + 30px);
}
@media (max-width: 900px) {
  .home-play-context {
    display: grid;
    gap: 2px;
  }
}
@media (max-width: 760px) {
  body.has-play-dock {
    --home-dock-reserve: 158px;
  }
  body.has-play-dock .home-art-window .expedition-art {
    max-width: 100%;
  }
  body.has-play-dock .app-dock {
    bottom: 0;
    width: 100%;
    border-radius: 24px 24px 0 0;
    border-bottom: 0;
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
    padding: 9px max(8px, var(--safe-left, 0px))
      calc(10px + var(--safe-bottom, env(safe-area-inset-bottom)))
      max(8px, var(--safe-right, 0px));
  }
  body.has-play-dock #home-play-slot {
    padding: 0 2px;
  }
  .home-play-context {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  body.has-play-dock #start-main {
    min-height: 56px;
    font-size: 18px;
  }
  body.has-play-dock .app-dock .bottom-nav button {
    min-height: 65px;
    padding-bottom: 5px;
    border-radius: 18px;
  }
  body.has-play-dock .app-dock .bottom-nav .illustrated-icon {
    width: 44px;
    height: 44px;
  }
  body.has-play-dock .app-dock .nav-label {
    font-size: 10px;
  }
  .home-updates {
    margin: 3px auto 24px;
  }
  .home-updates-heading {
    margin-bottom: 10px;
  }
  .home-updates-heading h2 {
    font-size: 22px;
  }
  .home-updates-heading > span {
    font-size: 8px;
  }
  .home-updates-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }
  .home-update-card,
  .home-updates .poems-entry {
    min-height: 110px;
    padding: 10px;
    gap: 10px;
    border-radius: 21px;
  }
  .home-update-art {
    width: 84px;
    height: 86px;
  }
  .home-update-art img {
    width: 80px;
    height: 80px;
  }
  .home-update-art img:first-child {
    width: 45px;
    height: 45px;
    top: 40px;
  }
  .home-updates .poems-entry > img {
    width: 80px;
    height: 80px;
  }
  .home-update-card strong,
  .home-updates .poems-entry strong {
    font-size: 17px;
  }
  .home-update-card span > span,
  .home-updates .poems-entry span > span {
    font-size: 11px;
  }
}
@media (max-width: 760px) and (max-height: 650px) {
  body.has-play-dock .home-art-window .expedition-art {
    aspect-ratio: 1200 / 930;
  }
}

body[data-screen="journey"] .app-dock {
  width: min(880px, calc(100% - 48px));
}
.app-dock .journey-actions {
  position: static;
  width: 100%;
  transform: none;
  padding: 0;
  margin: 0;
  border: 0;
  background: none;
  box-shadow: none;
}
.app-dock .journey-actions .primary {
  min-height: 58px;
  border-radius: 19px;
}
.home-hub-hero .home-art-guide {
  left: 64%;
  width: 34%;
  top: 13%;
  height: 87%;
}
@media (max-width: 760px) {
  body[data-screen="journey"] .app-dock {
    width: 100%;
  }
  .app-dock .journey-actions > span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  .app-dock .journey-actions .primary {
    min-height: 56px;
    font-size: 18px;
  }
  .home-hub-hero .home-art-guide {
    left: 45%;
    width: 58%;
    top: 17%;
    height: 83%;
  }
}

body.has-play-dock .app {
  padding-bottom: calc(
    var(--play-dock-height, var(--home-dock-reserve)) + 36px
  );
}
html:has(body.has-play-dock) {
  scroll-padding-block: 90px calc(var(--play-dock-height, 160px) + 28px);
}
body.has-play-dock .theme-card {
  scroll-margin-block: 12px 16px;
}
