:root {
  --teal: #3d6e7c;
  --teal-dark: #295d6d;
  --cyan: #00e8ff;
  --soft-line: rgba(0, 0, 0, 0.22);
  --panel-text: #666;
}

* {
  box-sizing: border-box;
}

html,
body,
#app {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
  font-family: Arial, Helvetica, sans-serif;
  background: linear-gradient(#f8fbff, #eef6ff);
}

button {
  font: inherit;
}

.viewport {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
}

.viewport canvas,
.unit-viewport canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}

#app.modal-open .viewport {
  filter: blur(10px);
  pointer-events: none;
}

#app.modal-open.snapshot-ready .viewport {
  filter: none;
  opacity: 0;
}

.main-snapshot {
  position: fixed;
  inset: 0;
  z-index: 1;
  background-position: center;
  background-size: cover;
  filter: blur(10px);
  opacity: 0.62;
  transform: scale(1.02);
  pointer-events: none;
}

.main-snapshot[hidden] {
  display: none;
}

#app.modal-open .top-control-rack,
#app.modal-open .camera-instruction,
#app.modal-open .unit-tag,
#app.modal-open .joystick {
  opacity: 0;
  pointer-events: none;
}

.top-control-rack {
  position: fixed;
  top: 14px;
  left: 50%;
  z-index: 8;
  display: grid;
  grid-template-columns: auto auto auto;
  grid-template-rows: auto auto;
  gap: 10px;
  align-items: stretch;
  transform: translateX(-50%);
}

.view-panel,
.sun-panel {
  border: 1px solid rgba(0, 232, 255, 0.30);
  border-radius: 8px;
  color: #dfffff;
  background: rgba(31, 48, 52, 0.78);
  box-shadow: 0 12px 28px rgba(18, 45, 58, 0.20);
  backdrop-filter: blur(6px);
}

.view-panel {
  display: grid;
  gap: 7px;
  padding: 10px;
  min-height: 112px;
}

.control-panel-title {
  color: var(--cyan);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 1.2px;
  line-height: 1;
}

.top-camera-bar {
  display: flex;
  gap: 5px;
}

.camera-button {
  min-width: 52px;
  height: 27px;
  border: 1px solid rgba(0, 232, 255, 0.65);
  border-radius: 4px;
  color: #dfffff;
  background: rgba(32, 48, 52, 0.82);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
}

.view-help {
  align-self: end;
  color: rgba(255, 255, 255, 0.82);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.25;
  white-space: nowrap;
}

.control-key {
  color: #55d9ef;
  font-weight: 900;
}

.cgon-camera-buttons .camera-button.is-active:not(.camera-auto-toggle) {
  color: var(--cgon-cyan-2) !important;
  background: rgba(255, 255, 255, 0.58) !important;
  box-shadow:
    inset 2px 2px 5px rgba(93, 106, 108, 0.14),
    inset -2px -2px 5px rgba(255, 255, 255, 0.72);
}

.cgon-camera-buttons .camera-auto-toggle {
  color: #fff !important;
  min-width: 72px;
  flex: 0 0 72px;
}

.cgon-camera-buttons .camera-auto-toggle.is-active {
  color: var(--cgon-cyan-2) !important;
  border-color: rgba(255, 255, 255, 0.72) !important;
  background: linear-gradient(180deg, rgba(247, 249, 248, 0.92), rgba(211, 217, 215, 0.86)) !important;
  box-shadow:
    4px 5px 10px rgba(79, 90, 92, 0.25),
    -3px -3px 8px rgba(255, 255, 255, 0.78),
    inset 1px 1px 0 rgba(255, 255, 255, 0.65);
}

.cgon-camera-buttons .camera-auto-toggle:not(.is-active) {
  color: #fff !important;
  background: rgba(118, 126, 130, 0.82) !important;
}

.camera-button:disabled {
  opacity: 0.45;
  cursor: default;
}

.camera-instruction {
  grid-column: 2 / 4;
  justify-self: center;
  z-index: 8;
  padding: 7px 14px;
  border: 1px solid rgba(0, 232, 255, 0.32);
  border-radius: 4px;
  color: #24505e;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 4px 16px rgba(36, 70, 86, 0.12);
  font-size: 14px;
  font-weight: 700;
  pointer-events: none;
}

.sun-panel {
  display: grid;
  grid-template-columns: repeat(5, minmax(74px, 1fr));
  gap: 6px;
  width: 520px;
  padding: 10px;
  min-height: 112px;
}

.sun-panel .control-panel-title {
  grid-column: 1 / -1;
}

.sun-panel label {
  display: grid;
  gap: 3px;
  min-width: 0;
  color: #29464f;
  font-size: 12px;
  font-weight: 700;
}

.sun-panel label span {
  color: #29464f;
  font-size: 12px;
  line-height: 1.15;
}

.sun-panel input {
  width: 100%;
  height: 26px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 4px;
  color: #14333d;
  background: rgba(255, 255, 255, 0.92);
  font-size: 12px;
}

.sun-panel button {
  align-self: end;
  height: 26px;
  border: 1px solid rgba(0, 232, 255, 0.62);
  border-radius: 4px;
  color: #10262e;
  background: rgba(0, 232, 255, 0.86);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.sun-readout {
  grid-column: 1 / -1;
  align-self: center;
  min-width: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 11px;
  line-height: 1.25;
}

.unit-tag {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 8;
  min-width: 0;
  height: auto;
  padding: 0;
  color: var(--cyan);
  background: transparent;
  transform: translate3d(0, 0, 0) translate(-50%, -100%);
  will-change: transform;
  text-align: center;
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.unit-tag span {
  display: inline-flex;
  align-items: center;
  height: 35px;
  padding: 0 15px;
  border: 1px solid var(--cyan);
  border-radius: 4px;
  background: rgba(16, 41, 45, 0.94);
  font-size: 18px;
  font-weight: 700;
}

.unit-tag-button {
  height: 35px;
  padding: 0 15px;
  border: 1px solid rgba(0, 232, 255, 0.75);
  border-radius: 4px;
  color: #eaffff;
  background: linear-gradient(90deg, rgba(36, 78, 93, 0.96), rgba(63, 119, 135, 0.96));
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.2);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.joystick {
  position: relative;
  width: 86px;
  height: 104px;
  touch-action: none;
}

.joystick-label {
  height: 18px;
  color: rgba(0, 232, 255, 0.84);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 1.6px;
  text-align: center;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.24);
}

.joystick-ring {
  position: relative;
  width: 100%;
  height: 86px;
  border: 1px solid rgba(0, 232, 255, 0.45);
  border-radius: 50%;
  background: rgba(28, 55, 64, 0.24);
  backdrop-filter: blur(4px);
}

.joystick-knob {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 34px;
  height: 34px;
  border: 2px solid rgba(255, 255, 255, 0.74);
  border-radius: 50%;
  background: rgba(0, 232, 255, 0.56);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.18);
  transform: translate(-50%, -50%);
}

.loading,
.unit-loading {
  position: fixed;
  left: 50%;
  top: 50%;
  z-index: 10;
  padding: 12px 18px;
  color: #14333d;
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 5px;
  transform: translate(-50%, -50%);
}

.loading.is-hidden,
.unit-loading.is-hidden {
  display: none;
}

.unit-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 5.8vh 6.8vw;
  background: rgba(255, 255, 255, 0.12);
}

.unit-modal[hidden] {
  display: none;
}

.unit-window {
  position: relative;
  width: min(1720px, 91vw);
  height: min(1080px, 84vh);
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 34px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 22px 70px rgba(40, 70, 92, 0.20), inset 0 0 0 1px rgba(255, 255, 255, 0.72);
}

.unit-titlebar {
  position: absolute;
  left: 0;
  top: 56px;
  z-index: 2;
  display: flex;
  align-items: center;
  width: 650px;
  height: 46px;
  padding-left: 180px;
  background: rgba(69, 95, 100, 0.9);
}

.unit-titlebar h1 {
  margin: 0;
  color: #fff;
  font-size: 26px;
  font-weight: 700;
  white-space: nowrap;
}

.unit-plan-button {
  position: absolute;
  left: 14px;
  top: 14px;
  z-index: 3;
  height: 34px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.52);
  border-radius: 4px;
  color: #fff;
  background: rgba(23, 58, 68, 0.56);
  font-size: 15px;
  font-weight: 800;
  white-space: nowrap;
  cursor: pointer;
}

.unit-plan-button:hover {
  background: rgba(18, 76, 92, 0.76);
}

.unit-view-help {
  position: absolute;
  left: 180px;
  top: 108px;
  z-index: 3;
  color: rgba(92, 109, 113, 0.92);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.close-button {
  position: absolute;
  top: 26px;
  right: 34px;
  width: 52px;
  height: 52px;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.close-button::before,
.close-button::after {
  position: absolute;
  left: 25px;
  top: 5px;
  width: 2px;
  height: 43px;
  content: "";
  background: #747474;
}

.close-button::before {
  transform: rotate(45deg);
}

.close-button::after {
  transform: rotate(-45deg);
}

.unit-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 470px;
  gap: 30px;
  width: 100%;
  height: 100%;
  padding: 142px 56px 56px 60px;
}

.unit-render-wrap {
  position: relative;
  min-width: 0;
  min-height: 0;
  background: #fff;
}

.unit-viewport {
  width: 100%;
  height: 100%;
  background: #fff;
}

.unit-loading {
  position: absolute;
}

.config-panel {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  row-gap: 10px;
  min-width: 0;
  min-height: 0;
  padding: 0 0 0 8px;
}

.config-scroll {
  overflow-y: auto;
  padding: 0 18px 0 0;
  scrollbar-color: #a9a9a9 transparent;
  scrollbar-width: thin;
}

.config-scroll::-webkit-scrollbar {
  width: 10px;
}

.config-scroll::-webkit-scrollbar-thumb {
  border-radius: 8px;
  background: #aaa;
}

.option-group {
  margin-bottom: 20px;
}

.option-group h2 {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 10px;
  color: #111;
  font-size: 26px;
  font-weight: 700;
}

.option-group h2::after {
  display: block;
  flex: 1;
  height: 1px;
  content: "";
  background: var(--soft-line);
}

.option-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px 10px;
}

.option-button {
  min-width: 0;
  padding: 0;
  border: 0;
  color: var(--panel-text);
  background: transparent;
  cursor: pointer;
}

.option-thumb {
  display: block;
  width: 100%;
  aspect-ratio: 1.42;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.13);
  border-radius: 14px;
  background-position: center;
  background-size: cover;
  box-shadow: inset 0 0 0 0 rgba(80, 169, 235, 0);
}

.option-button.is-active .option-thumb {
  border-color: #45aeea;
  box-shadow: inset 0 0 0 2px rgba(63, 171, 232, 0.88), 0 0 0 1px rgba(63, 171, 232, 0.30);
}

.option-name {
  display: block;
  margin-top: 6px;
  overflow: hidden;
  font-size: 16px;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.download-button {
  align-self: end;
  width: calc(100% - 18px);
  height: 66px;
  margin-top: 0;
  border: 0;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(90deg, #245a6a, #416f7c);
  font-size: 32px;
  font-weight: 700;
  cursor: pointer;
}

@media (max-width: 1100px) {
  .unit-window {
    width: 96vw;
    height: 90vh;
    border-radius: 22px;
  }

  .unit-content {
    grid-template-columns: 1fr;
    grid-template-rows: minmax(320px, 1fr) 42vh;
    padding: 132px 24px 24px;
  }

  .config-panel {
    grid-template-rows: minmax(0, 1fr) auto;
  }

  .unit-titlebar {
    width: 64vw;
    height: 44px;
    padding-left: 7vw;
  }

  .unit-titlebar h1 {
    font-size: 22px;
  }

  .unit-plan-button {
    left: 10px;
    top: 10px;
    height: 32px;
    padding: 0 10px;
    font-size: 13px;
  }

  .unit-view-help {
    left: 7vw;
    top: 106px;
    font-size: 12px;
  }

  .close-button {
    right: 24px;
  }

  .download-button {
    height: 58px;
    font-size: 24px;
  }
}

@media (max-width: 720px) {
  .top-control-rack {
    top: 10px;
    left: 10px;
    right: 10px;
    grid-template-columns: 86px minmax(0, 1fr);
    grid-template-rows: auto auto;
    gap: 8px;
    transform: none;
  }

  .joystick {
    grid-row: 1 / 3;
    grid-column: 1;
  }

  .view-panel {
    grid-row: 1;
    grid-column: 2;
    min-width: 0;
  }

  .view-help {
    white-space: normal;
  }

  .top-camera-bar {
    flex-wrap: wrap;
  }

  .camera-button {
    min-width: 46px;
    height: 26px;
  }

  .sun-panel {
    grid-row: 2;
    grid-column: 2;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    width: auto;
    min-width: 0;
    overflow: hidden;
  }

  .sun-panel label:nth-of-type(1) {
    grid-column: 1;
  }

  .sun-panel label:nth-of-type(2) {
    grid-column: 2;
  }

  .sun-panel label:nth-of-type(3) {
    grid-column: 3;
  }

  .sun-panel label:nth-of-type(4) {
    grid-column: 1 / 3;
  }

  .sun-panel button {
    grid-column: 3;
  }

  .sun-panel input {
    min-width: 0;
    font-size: 11.5px;
    padding: 0 5px;
  }

  .sun-panel button {
    min-width: 0;
    width: 100%;
    padding: 0 4px;
  }

  .sun-panel .control-panel-title,
  .sun-readout {
    grid-column: 1 / -1;
  }

  .camera-instruction {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    top: auto;
    bottom: 16px;
    width: calc(100vw - 28px);
    text-align: center;
    font-size: 12px;
  }

  .unit-plan-button {
    left: 10px;
    right: auto;
    top: 10px;
  }

  .unit-view-help {
    left: 7vw;
    right: auto;
    top: 106px;
  }
}

.cgon-joystick.joystick {
  position: fixed;
  left: 22px;
  bottom: 24px;
  z-index: 1001;
  width: 148px;
  height: 166px;
}

.cgon-joystick .joystick-label {
  color: rgba(255, 255, 255, 0.9);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.38);
}

.cgon-joystick .joystick-ring {
  height: 148px;
  background: rgba(28, 55, 64, 0.24);
}

.cgon-joystick .joystick-knob {
  width: 46px;
  height: 46px;
}

#app.modal-open .cgon-site-jump-nav,
#app.modal-open .cgon-topbar,
#app.modal-open .cgon-instruction,
#app.modal-open .cgon-panel {
  opacity: 0;
  pointer-events: none;
}

.sun-panel.cgon-panel {
  display: block;
  width: min(390px, calc(100vw - 28px));
  min-height: 0;
  padding: 16px;
  color: var(--cgon-ink, #263033);
  background:
    linear-gradient(180deg, rgba(248, 250, 249, 0.78), rgba(215, 220, 218, 0.68)),
    rgba(232, 235, 234, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.55);
  box-shadow:
    12px 16px 40px rgba(0, 0, 0, 0.26),
    inset 1px 1px 0 rgba(255, 255, 255, 0.82),
    inset -1px -1px 0 rgba(92, 104, 106, 0.12);
}

.sun-panel.cgon-panel.is-hidden {
  display: none;
}

.cgon-toolbar .cgon-camera-buttons {
  flex: 0 1 360px;
}

#sunPanelToggle {
  flex: 0 0 auto;
  min-width: 132px;
  justify-content: center;
  color: #ffffff;
  border-color: rgba(92, 219, 225, 0.72);
  background: linear-gradient(180deg, rgba(104, 216, 224, 0.96), rgba(34, 159, 172, 0.92));
  box-shadow:
    4px 5px 10px rgba(79, 90, 92, 0.22),
    inset 1px 1px 0 rgba(255, 255, 255, 0.5);
}

.sun-panel .cgon-panel-section {
  border-top: 0;
  padding-top: 0;
}

.sun-panel .sun-panel-close {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 30px;
  height: 30px !important;
  min-height: 30px !important;
  padding: 0;
  border: 0 !important;
  border-radius: 0;
  background: transparent !important;
  box-shadow: none !important;
  cursor: pointer;
  color: transparent !important;
  align-self: auto;
}

.sun-panel .sun-panel-close::before,
.sun-panel .sun-panel-close::after {
  position: absolute;
  left: 14px;
  top: 5px;
  width: 2px;
  height: 20px;
  content: "";
  background: rgba(85, 217, 239, 0.9);
}

.sun-panel .sun-panel-close::before {
  transform: rotate(45deg);
}

.sun-panel .sun-panel-close::after {
  transform: rotate(-45deg);
}

.sun-panel .sun-panel-close:hover {
  background: transparent !important;
  box-shadow: none !important;
}

.cgon-site-jump-nav a {
  color: rgba(36, 48, 52, 0.92);
}

.cgon-site-jump-btn,
.cgon-site-jump-icon {
  color: rgba(36, 48, 52, 0.92);
  border-color: rgba(36, 48, 52, 0.48);
}

.cgon-site-jump-nav .cgon-site-jump-btn:hover {
  color: rgba(36, 48, 52, 0.92);
  border-color: transparent;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: none;
}

.cgon-site-jump-nav .cgon-site-jump-icon:hover {
  color: rgba(36, 48, 52, 0.92);
  border-color: transparent;
  background: transparent;
}

.cgon-home-logo {
  flex: 0 0 auto;
  color: rgba(36, 48, 52, 0.92);
  width: auto;
  padding: 0 8px;
  margin-right: 10px;
  border-color: rgba(255, 255, 255, 0.28);
  border-radius: 6px;
  background: rgba(30, 39, 42, 0.72);
  box-shadow: 0 5px 14px rgba(0, 0, 0, 0.18);
}

.cgon-site-jump-nav .cgon-home-logo:hover {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(30, 39, 42, 0.82);
}

.cgon-site-jump-btn.cgon-site-jump-current {
  color: #ffffff;
  border-color: rgba(92, 219, 225, 0.72);
  background: linear-gradient(180deg, rgba(104, 216, 224, 0.96), rgba(34, 159, 172, 0.92));
}

.sun-panel.cgon-panel h2 {
  color: var(--cgon-cyan-2, #0b7180);
}

.sun-panel .cgon-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.sun-panel input {
  min-height: 34px;
  height: 34px;
  padding: 0 9px;
  color: var(--cgon-ink, #263033);
  background: linear-gradient(180deg, rgba(247, 249, 248, 0.92), rgba(211, 217, 215, 0.86));
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 11px;
  box-shadow:
    4px 5px 10px rgba(79, 90, 92, 0.18),
    -3px -3px 8px rgba(255, 255, 255, 0.62),
    inset 1px 1px 0 rgba(255, 255, 255, 0.65);
}

.sun-panel button {
  width: auto;
  box-shadow: none;
}

#applySunButton {
  grid-column: 2;
  grid-row: 3;
  justify-self: end;
  min-width: 86px;
  height: 34px;
  min-height: 34px;
  color: #f4ffff;
  border-color: rgba(22, 143, 159, 0.62);
  background: linear-gradient(180deg, #1aa6b8, #087381);
  box-shadow:
    5px 7px 16px rgba(7, 113, 128, 0.22),
    inset 1px 1px 0 rgba(255, 255, 255, 0.34);
}

.sun-readout {
  grid-column: 1;
  grid-row: 3;
  align-self: center;
  min-height: 30px;
  margin: 0;
  padding: 6px 0;
  color: var(--cgon-muted, #6f7a7d);
  font-size: 12px;
  line-height: 1.2;
}

#aptHelpPanel {
  top: calc(var(--cgon-topbar-height) + 306px);
  max-height: calc(100vh - var(--cgon-topbar-height) - 330px);
}

.unit-view-help {
  display: block;
}

.close-button {
  top: 30px;
  right: 30px;
  width: 40px;
  height: 40px;
}

.close-button::before,
.close-button::after {
  left: 19px;
  top: 7px;
  height: 26px;
}

.unit-plan-button {
  left: 14px;
  right: auto;
  top: 14px;
  height: 34px;
  padding: 0 13px;
  font-size: 14px;
}

.loading.cgon-loading,
.unit-loading.cgon-loading {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: rgba(220, 224, 223, 0.62);
}

@media (max-width: 720px) {
  .cgon-home-logo {
    padding: 0 4px;
    margin-right: 0;
  }

  .cgon-toolbar .cgon-camera-buttons {
    flex: 1 1 100%;
    width: 100%;
    min-width: 0;
    justify-content: space-between;
  }

  #sunPanelToggle {
    flex: 1 1 100%;
    width: 100%;
    min-width: 0;
  }

  .cgon-joystick.joystick {
    left: 10px;
    bottom: 12px;
    width: 104px;
    height: 120px;
  }

  .cgon-joystick .joystick-ring {
    height: 104px;
  }

  .cgon-joystick .joystick-knob {
    width: 34px;
    height: 34px;
  }

  .cgon-joystick .joystick-label {
    font-size: 10px;
  }

  .sun-panel .cgon-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .sun-panel label:nth-of-type(1) {
    grid-column: 1;
  }

  .sun-panel label:nth-of-type(2) {
    grid-column: 2;
  }

  .sun-panel label:nth-of-type(3) {
    grid-column: 1;
  }

  .sun-panel label:nth-of-type(4) {
    grid-column: 2;
  }

  #applySunButton {
    grid-column: 2;
    justify-self: end;
  }

  .sun-readout {
    grid-column: 1;
  }

  .sun-panel.cgon-panel {
    left: 10px;
    right: 10px;
    top: calc(38px + var(--cgon-topbar-height) + 8px);
    bottom: auto;
    width: auto;
    max-height: 128px;
    padding: 10px;
    overflow: auto;
  }

  .cgon-help-panel {
    top: auto !important;
    bottom: 10px;
    max-height: 38vh;
  }

  .sun-panel.cgon-panel h2 {
    margin-bottom: 8px;
    font-size: 13px;
  }

  .sun-panel label span {
    font-size: 10.5px;
  }

  .sun-panel input {
    height: 26px;
    min-height: 26px;
    font-size: 12px;
  }

  #applySunButton {
    height: 26px;
    min-height: 26px;
  }

  .sun-readout {
    min-height: 26px;
    padding: 4px 0;
    font-size: 10.5px;
  }

  .cgon-instruction {
    top: calc(38px + var(--cgon-topbar-height) + 4px);
  }

  .unit-plan-button {
    left: 10px;
    right: auto;
    top: 10px;
    height: 30px;
    font-size: 12px;
  }

  .close-button {
    top: 22px;
    right: 22px;
    width: 34px;
    height: 34px;
  }

  .close-button::before,
  .close-button::after {
    left: 16px;
    top: 6px;
    height: 22px;
  }
}
