#startScreen .start-screen-content {
  width: min(41vw, 470px);
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: clamp(10px, 3vh, 28px);
  padding-block: 5px;
}

#startScreen h1 {
  width: min(100%, 420px);
  margin: 0;
  line-height: 0;
}

#startScreen h1 img {
  width: 100%;
  max-height: 28dvh;
  object-fit: contain;
  filter: drop-shadow(0 3px 8px #091a17aa);
}

#startScreen .start-screen-menu {
  width: min(100%, 374px);
  padding: 0;
  border: 0;
  background: none;
  box-shadow: none;
  gap: clamp(5px, 1.25vh, 12px);
}

#startScreen .start-screen-menu button {
  min-height: clamp(46px, 8.8vh, 68px);
  padding: 6px 14%;
  background: url("./assets/harbor-ui-menu-v1.webp") center / 100% 100% no-repeat;
  font: 700 clamp(15px, 1.66vw, 23px)/1.15 system-ui, sans-serif;
}

#startScreen .start-screen-menu button:first-of-type {
  background-image: url("./assets/harbor-ui-buy-v1.webp");
  color: #2e1d0b;
  text-shadow: none;
  filter: none;
}

@media (orientation: landscape) and (max-height: 450px) {
  #startScreen .start-screen-content { width: min(40vw, 335px); gap: 5px; }
  #startScreen h1 img { max-height: min(23dvh, 92px); }
  #startScreen .start-screen-menu button { min-height: 44px; font-size: 15px; }
}

@media (orientation: portrait) {
  #startScreen .start-screen-content { width: min(85vw, 410px); }
}

body #game:has(#world:is([data-scene="finance"], [data-scene="bank"], [data-scene="server"])) nav#dock {
  display: flex;
  flex-flow: row nowrap;
  justify-content: center;
  width: auto !important;
  left: var(--touch-left, 0px) !important;
  right: var(--touch-right, 0px) !important;
  transform: none !important;
  margin-inline: 0 !important;
  pointer-events: none;
}

body #game:has(#world:is([data-scene="finance"], [data-scene="bank"], [data-scene="server"])) nav#dock > button {
  width: clamp(100px, 14vw, 210px);
  pointer-events: auto;
}

#game #dock .hall-dock-icon {
  display: block;
  width: 43%;
  height: 50%;
  margin: 0 auto 3px;
  object-fit: contain;
}

#game #panel[data-kind="jewels"] .jewel-pack-grid {
  --jewel-card-size: 190px;
  grid-template-columns: repeat(4, minmax(0, var(--jewel-card-size)));
  justify-content: center;
  gap: clamp(5px, 1vw, 13px);
}

#game #panel[data-kind="jewels"] .jewel-gold .jewel-pack-grid {
  grid-template-columns: repeat(2, minmax(0, var(--jewel-card-size))) !important;
}

body.handset-landscape #game #panel[data-kind="jewels"] .jewel-pack-grid {
  --jewel-card-size: 114px;
}

#game #panel[data-kind="jewels"] .jewel-pack {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: clamp(3px, .55vw, 8px);
  aspect-ratio: 1;
  min-height: 0;
  padding: clamp(6px, 1.1vw, 16px);
  background: url("./assets/harbor-ui-shop-v1.webp") center / 100% 100% no-repeat;
  border: 0;
  border-radius: 0;
  color: #fff1c9;
}

#game #panel[data-kind="jewels"] .jewel-pack > div { gap: 0 5px; margin-top: auto; }
#game #panel[data-kind="jewels"] .jewel-pack :is(strong,h3) {
  margin: 0;
  color: #fff1c9;
  font-size: clamp(14px, 1.85vw, 28px);
  line-height: 1.1;
}
#game #panel[data-kind="jewels"] #panelBody .jewel-gold .jewel-pack h3 {
  padding: 0;
  background: none;
  color: #fff1c9;
  font-size: clamp(13px, 1.7vw, 23px);
  line-height: 1.1;
}
#game #panel[data-kind="jewels"] .jewel-pack .gold-exchange-icon {
  align-self: center;
  width: 21%;
  max-width: 34px;
  aspect-ratio: 1;
  height: auto;
  object-fit: contain;
  margin-top: auto;
}
#game #panel[data-kind="jewels"] .jewel-pack .jewel-discount {
  align-self: center;
  font-size: clamp(10px, 1.05vw, 15px);
  line-height: 1;
  color: #312006;
  background: #e9be6e;
}
#game #panel[data-kind="jewels"] #panelBody .jewel-pack button.jewel-price {
  flex: 0 0 auto;
  width: 100%;
  min-height: clamp(29px, 4.3vw, 47px);
  margin: auto 0 0;
  padding: 3px 8%;
  border: 0;
  box-shadow: none;
  background: url("./assets/harbor-ui-buy-v1.webp") center / 100% 100% no-repeat;
  color: #261807;
  text-shadow: none;
  font-size: clamp(11px, 1.35vw, 19px);
  line-height: 1.1;
  cursor: pointer;
}

#game #panel[data-kind="jewels"] #panelBody .jewel-gold .jewel-pack button.jewel-price > span {
  color: inherit;
  font: inherit;
  line-height: inherit;
}

@media (max-width: 600px) and (orientation: portrait) {
  #game #panel[data-kind="jewels"] .jewel-pack-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.city-scenery-group { margin-block: 10px 18px; }
.city-scenery-grid {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 8px;
}
#game #panelBody .city-scenery-card {
  min-width: 0;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 5px;
  margin: 0;
  padding: 6px;
  text-align: center;
}
.city-scenery-card h4 { margin: 0; line-height: 1.2; }
.city-scenery-preview img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 32/15;
  object-fit: cover;
  border-radius: 4px;
  background: #1f3e39;
}
.city-scenery-light {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 3px;
  margin-top: 4px;
}
#game #panelBody .city-scenery-light button {
  min-width: 0;
  margin: 0;
  padding-inline: 2px;
}
#game #panelBody .city-scenery-light button.primary {
  box-shadow: inset 0 -3px #eccc76;
}
#game #panelBody .city-scenery-purchase { width: 100%; }
.energy-manager-progress {
  display: grid;
  gap: 4px;
  margin-block: 7px;
}
.energy-manager-progress p { margin: 0; }
.energy-manager-progress progress { width: 100%; accent-color: #49744e; }
body.handset-landscape .city-scenery-grid {
  grid-template-columns: repeat(3,minmax(0,168px));
  justify-content: center;
}
body.handset-landscape .city-scenery-card .city-scenery-preview img {
  max-height: 67px;
}
@media (max-width: 640px) and (orientation: portrait) {
  .city-scenery-grid { grid-template-columns: 1fr; }
}
