:root {
  color-scheme: dark;
  font-family: system-ui, sans-serif;
}

html,
body {
  height: 100%;
  margin: 0;
  overflow: hidden;
  background: #0b0d10;
}

canvas {
  display: block;
}

#world-map {
  position: fixed;
  z-index: 100;
  inset: 0;
  background: #071016;
}

#world-map[hidden] {
  display: none;
}

.map-open #top-right-huds,
.map-open #telemetry-hud,
.map-open #mining-hud,
.map-open #boundary-warning,
.map-open #crosshair,
.map-open #interaction-prompt,
.map-open #action-message,
.map-open #active-mode-hud,
.map-open #build-catalog,
.map-open #workshop-catalog,
.map-open #tool-wheel,
.map-open .lil-gui {
  display: none;
}

#hud {
  display: none;
}

#mining-hud {
  position: fixed;
  z-index: 10;
  top: 14px;
  left: 14px;
  width: 50px;
  padding: 5px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.78);
  background: rgba(8, 13, 17, 0.62);
  backdrop-filter: blur(7px);
  pointer-events: none;
}

#current-material-title {
  overflow: hidden;
  margin-bottom: 5px;
  color: #efffde;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 14px;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#boundary-warning {
  position: fixed;
  z-index: 10;
  top: 58px;
  left: 50%;
  padding: 7px 11px;
  border: 1px solid rgba(255, 196, 92, 0.36);
  border-radius: 6px;
  color: #ffd27a;
  background: rgba(38, 22, 8, 0.72);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  pointer-events: none;
  transform: translateX(-50%);
}

#boundary-warning[hidden] {
  display: none;
}

#resource-inventory {
  display: grid;
  gap: 3px;
}

.inventory-item {
  position: relative;
  display: flex;
  width: 48px;
  height: 42px;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 5px;
  box-sizing: border-box;
  transition:
    opacity 120ms ease,
    background 120ms ease,
    border-color 120ms ease;
}

.inventory-item.is-empty {
  opacity: 0.34;
}

.inventory-icon {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.inventory-count {
  position: absolute;
  right: 2px;
  bottom: 1px;
  min-width: 10px;
  padding: 0 2px;
  border-radius: 4px;
  color: #f6ffe9;
  background: rgba(5, 9, 12, 0.82);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 9px;
  font-weight: 800;
  line-height: 12px;
  text-align: center;
  text-shadow: 0 1px 2px #000;
}

#top-right-huds {
  position: fixed;
  z-index: 10;
  top: 14px;
  right: 14px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

#telemetry-hud {
  position: fixed;
  z-index: 12;
  top: 12px;
  left: 50%;
  display: flex;
  min-height: 38px;
  align-items: stretch;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  color: #f4f7fa;
  background: rgba(8, 13, 17, 0.66);
  box-shadow: 0 3px 18px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(7px);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  pointer-events: none;
  transform: translateX(-50%);
}

.hud-telemetry-value,
.hud-compass {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  white-space: nowrap;
}

.hud-telemetry-value,
.hud-compass + .hud-telemetry-value {
  border-left: 1px solid rgba(255, 255, 255, 0.12);
}

.hud-compass {
  min-width: 82px;
  justify-content: center;
  color: #e9ffd5;
}

.hud-compass-rose {
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border: 1px solid rgba(223, 244, 197, 0.3);
  border-radius: 50%;
  background: rgba(223, 244, 197, 0.06);
}

#compass-needle {
  display: block;
  color: #dff4c5;
  font-size: 11px;
  font-style: normal;
  line-height: 1;
  transform-origin: 50% 50%;
}

#compass-direction {
  min-width: 18px;
  text-align: center;
}

#compass-degrees {
  color: rgba(255, 255, 255, 0.56);
  font-size: 9px;
}

.hud-time {
  color: #dbeeff;
}

#gameplay-hud,
#test-hud {
  display: flex;
  width: 245px;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  color: #f4f7fa;
  background: rgba(8, 13, 17, 0.68);
  box-shadow: 0 3px 18px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(7px);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  pointer-events: auto;
}

#test-hud {
  font-size: 11px;
}

.hud-world-name {
  display: flex;
  min-height: 48px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 7px 11px;
  box-sizing: border-box;
  color: #e9ffd5;
  background: rgba(192, 238, 146, 0.07);
}

#test-hud .hud-world-name {
  min-height: 38px;
  flex-direction: row;
  justify-content: space-between;
  padding: 6px 10px;
}

#test-hud #world-name {
  font-size: 12px;
  line-height: 16px;
}

#world-name {
  overflow: hidden;
  max-width: 100%;
  font-size: 16px;
  letter-spacing: 0.08em;
  line-height: 20px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hud-coordinate {
  display: flex;
  min-width: 0;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 11px;
}

.hud-coordinate + .hud-coordinate {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.hud-world-name + .hud-coordinate {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.hud-altitude {
  color: #dff4c5;
}

.hud-performance {
  color: #f1e7b6;
}

.hud-triangles {
  min-width: 0;
}

.hud-label {
  color: rgba(255, 255, 255, 0.52);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.hud-gameplay-controls,
.hud-test-controls {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  pointer-events: auto;
}

.hud-action,
.hud-control {
  border: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: #f4f7fa;
  background: transparent;
  font: inherit;
}

.hud-action:first-child {
  border-top: 0;
}

.hud-action {
  min-height: 34px;
  padding: 8px 12px;
  color: #dff4c5;
  cursor: pointer;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.hud-action:hover,
.hud-action:focus-visible {
  outline: none;
  background: rgba(192, 238, 146, 0.16);
}

.hud-tool-controls,
.hud-building-controls {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.hud-tool-controls:first-child {
  border-top: 0;
}

.hud-test-metrics {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 6px 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: #f1e7b6;
  font-size: 10px;
}

.hud-catalog-action {
  display: flex;
  width: 100%;
  min-height: 38px;
  align-items: center;
  justify-content: space-between;
}

.hud-catalog-action.is-active {
  color: #efffd9;
  background: rgba(137, 216, 102, 0.22);
  box-shadow: inset 3px 0 0 #9ee678;
}

.hud-catalog-action > span {
  display: flex;
  align-items: center;
  gap: 5px;
}

.hud-action-icon {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.hud-catalog-action kbd {
  min-width: 18px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 4px;
  color: rgba(255, 255, 255, 0.68);
  background: rgba(0, 0, 0, 0.2);
  font: inherit;
  line-height: 18px;
  text-align: center;
}

.hud-build-cost {
  color: rgba(255, 255, 255, 0.68);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0;
}

.hud-active-tool,
.hud-active-build {
  padding: 9px 10px 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(137, 216, 102, 0.08);
}

.hud-active-tool[hidden],
.hud-active-build[hidden] {
  display: none;
}

.hud-tool-settings {
  margin-bottom: 5px;
  color: rgba(255, 255, 255, 0.68);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-align: center;
}

.hud-active-build-title {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 6px;
  color: #efffd9;
  font-size: 11px;
  letter-spacing: 0.03em;
}

.hud-active-build-title > img {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  object-fit: contain;
}

.hud-active-build .hud-build-cost {
  margin-bottom: 5px;
  text-align: center;
}

.hud-build-help {
  padding: 8px 10px;
  color: rgba(239, 255, 217, 0.8);
  font-size: 9px;
  line-height: 1.45;
  text-align: center;
}

.hud-active-tool .hud-build-help,
.hud-active-build .hud-build-help {
  padding: 0;
}

.hud-build-status {
  min-height: 0;
  margin-top: 4px;
  color: #ffd28a;
  font-size: 9px;
  line-height: 1.35;
  text-align: center;
}

.hud-build-status:empty {
  display: none;
}

#mineral-detector-panel {
  display: grid;
  gap: 6px;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(186, 224, 255, 0.18);
}

#mineral-detector-panel[hidden] {
  display: none;
}

.detector-scan-line {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: #bde5ff;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.detector-scan-track,
.detector-strength {
  overflow: hidden;
  border-radius: 999px;
  background: rgba(4, 12, 18, 0.72);
  box-shadow: inset 0 0 0 1px rgba(189, 229, 255, 0.12);
}

.detector-scan-track {
  height: 3px;
}

.detector-scan-track > i,
.detector-strength > i {
  display: block;
  width: 0;
  height: 100%;
  background: #67c8ff;
  transition: width 90ms linear;
}

.detector-results {
  display: grid;
  gap: 4px;
}

.detector-result {
  display: grid;
  grid-template-columns: 18px 42px minmax(36px, 1fr);
  align-items: center;
  gap: 4px 6px;
  padding: 4px 5px;
  border: 1px solid rgba(189, 229, 255, 0.08);
  border-radius: 5px;
  color: rgba(239, 255, 217, 0.58);
  background: rgba(3, 9, 13, 0.28);
}

.detector-result.has-signal {
  color: #efffd9;
  border-color: rgba(103, 200, 255, 0.22);
}

.detector-result.is-strongest {
  border-color: rgba(103, 200, 255, 0.64);
  background: rgba(22, 91, 128, 0.22);
}

.detector-result > img {
  width: 18px;
  height: 18px;
  grid-row: 1 / span 2;
  object-fit: contain;
  opacity: 0.48;
}

.detector-result.has-signal > img {
  opacity: 1;
}

.detector-result > span {
  font-size: 8px;
  font-weight: 700;
}

.detector-strength {
  height: 4px;
}

.detector-result small {
  grid-column: 2 / 4;
  overflow: hidden;
  color: rgba(189, 229, 255, 0.72);
  font-size: 7px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.build-mode #crosshair {
  color: #b8ff99;
}

.build-catalog-open #crosshair,
.build-catalog-open #interaction-prompt,
.build-catalog-open #action-message,
.workshop-catalog-open #crosshair,
.workshop-catalog-open #interaction-prompt,
.workshop-catalog-open #action-message,
.tool-wheel-open #crosshair,
.tool-wheel-open #interaction-prompt,
.tool-wheel-open #action-message {
  display: none;
}

#build-catalog,
.overlay-catalog {
  position: fixed;
  z-index: 200;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  box-sizing: border-box;
  background: rgba(5, 9, 12, 0.68);
  backdrop-filter: blur(8px);
}

#build-catalog[hidden],
.overlay-catalog[hidden] {
  display: none;
}

.build-catalog-panel {
  width: min(760px, 100%);
  max-height: min(680px, calc(100vh - 48px));
  overflow: auto;
  border: 1px solid rgba(220, 244, 198, 0.24);
  border-radius: 12px;
  color: #f4f7fa;
  background: rgba(12, 19, 24, 0.96);
  box-shadow: 0 18px 70px rgba(0, 0, 0, 0.48);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
}

.build-catalog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 20px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.build-catalog-header h2 {
  margin: 4px 0 0;
  color: #efffd9;
  font-size: 19px;
  letter-spacing: 0.02em;
}

#build-catalog-close {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 7px;
  color: rgba(255, 255, 255, 0.72);
  background: rgba(255, 255, 255, 0.05);
  cursor: pointer;
  font-size: 24px;
  line-height: 28px;
}

#build-catalog-content {
  display: grid;
  gap: 18px;
  padding: 18px 20px 22px;
}

.build-catalog-section h3 {
  margin: 0 0 8px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.build-catalog-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.build-catalog-card {
  display: flex;
  min-height: 92px;
  align-items: center;
  gap: 13px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 8px;
  color: #f4f7fa;
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.build-catalog-card:hover,
.build-catalog-card:focus-visible {
  outline: none;
  border-color: rgba(183, 235, 139, 0.6);
  background: rgba(137, 216, 102, 0.13);
}

.build-catalog-card.is-unavailable {
  border-color: rgba(255, 191, 107, 0.2);
}

.build-catalog-icon {
  width: 54px;
  height: 54px;
  flex: 0 0 54px;
  object-fit: contain;
}

.build-catalog-card-text {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 4px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 10px;
  line-height: 1.35;
}

.build-catalog-card-text strong {
  color: #efffd9;
  font-size: 12px;
}

.build-catalog-card-cost {
  color: #f0dba2;
  font-weight: 700;
}

.resource-inline-icon {
  display: inline-block;
  width: 20px;
  height: 20px;
  margin: -5px 2px -5px 0;
  object-fit: contain;
  vertical-align: middle;
}

.build-catalog-panel footer {
  padding: 10px 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.42);
  font-size: 9px;
  text-align: center;
}

.workshop-catalog-panel,
.tool-wheel-panel {
  width: min(520px, 100%);
  overflow: hidden;
  border: 1px solid rgba(220, 244, 198, 0.24);
  border-radius: 12px;
  color: #f4f7fa;
  background: rgba(12, 19, 24, 0.97);
  box-shadow: 0 18px 70px rgba(0, 0, 0, 0.48);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
}

.workshop-catalog-panel h2,
.tool-wheel-panel h2 {
  margin: 4px 0 0;
  color: #efffd9;
  font-size: 19px;
}

#workshop-catalog-close {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 7px;
  color: rgba(255, 255, 255, 0.72);
  background: rgba(255, 255, 255, 0.05);
  cursor: pointer;
  font-size: 24px;
}

.workshop-tool-content {
  display: grid;
  gap: 10px;
  padding: 18px 20px;
}

.workshop-tool-card {
  width: 100%;
}

.workshop-tool-card.is-unlocked {
  border-color: rgba(137, 216, 102, 0.55);
}

.workshop-tool-card:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.workshop-catalog-panel footer,
.tool-wheel-panel footer {
  padding: 10px 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.42);
  font-size: 9px;
  text-align: center;
}

.tool-wheel-panel {
  width: min(560px, 100%);
  padding-top: 18px;
  text-align: center;
}

.tool-wheel-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding: 20px;
}

.tool-wheel-option {
  display: flex;
  min-height: 132px;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 50%;
  color: #efffd9;
  background: rgba(255, 255, 255, 0.05);
  cursor: pointer;
  flex-direction: column;
  font: inherit;
}

.tool-wheel-icon {
  width: 66px;
  height: 66px;
  object-fit: contain;
}

.tool-wheel-option small {
  max-width: 110px;
  color: rgba(255, 255, 255, 0.44);
  font-size: 8px;
}

.tool-wheel-option:hover:not(:disabled),
.tool-wheel-option:focus-visible,
.tool-wheel-option.is-active {
  outline: none;
  border-color: rgba(183, 235, 139, 0.65);
  background: rgba(137, 216, 102, 0.14);
}

.tool-wheel-option:disabled {
  cursor: not-allowed;
  filter: grayscale(0.75);
  opacity: 0.42;
}

@media (max-width: 620px) {
  .build-catalog-grid {
    grid-template-columns: 1fr;
  }
}

.hud-control {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 6px 10px;
}

.hud-control input {
  height: 24px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 4px;
  box-sizing: border-box;
  color: #f4f7fa;
  background: rgba(255, 255, 255, 0.07);
  font: inherit;
  font-size: 11px;
  text-align: center;
}

.hud-control-value {
  display: flex;
  align-items: center;
  gap: 5px;
}

.hud-checkbox-control input[type="checkbox"] {
  width: 15px;
  height: 15px;
  margin: 0;
  accent-color: #9ee678;
  cursor: pointer;
}

#view-distance-input {
  width: 43px;
}

#time-of-day-input {
  width: 72px;
}

.hud-unit {
  color: rgba(255, 255, 255, 0.46);
  font-size: 9px;
  font-weight: 700;
}

#developer-gui-container {
  width: 245px;
}

#developer-gui-container > .lil-gui.root {
  position: static;
  width: 245px;
}

@media (max-width: 900px) {
  #telemetry-hud {
    left: 76px;
    transform: none;
  }

  #compass-degrees {
    display: none;
  }

  .hud-compass {
    min-width: 54px;
  }

  .hud-telemetry-value,
  .hud-compass {
    padding-right: 7px;
    padding-left: 7px;
  }
}

#crosshair {
  position: fixed;
  top: 50%;
  left: 50%;
  width: 10px;
  height: 10px;
  margin-top: -5px;
  margin-left: -5px;
  opacity: 0.2;
  pointer-events: none;
}

#crosshair::before,
#crosshair::after {
  position: absolute;
  content: "";
  background: white;
}

#crosshair::before {
  top: 0;
  left: 4px;
  width: 2px;
  height: 10px;
}

#crosshair::after {
  top: 4px;
  left: 0;
  width: 10px;
  height: 2px;
}

#active-mode-hud {
  position: fixed;
  z-index: 15;
  bottom: 22px;
  left: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 104px;
  padding: 5px 8px 7px;
  border: 1px solid rgba(210, 232, 193, 0.3);
  border-radius: 11px;
  color: white;
  background: rgba(8, 13, 17, 0.72);
  box-shadow:
    0 5px 20px rgba(0, 0, 0, 0.34),
    inset 0 0 16px rgba(187, 226, 154, 0.06);
  backdrop-filter: blur(7px);
  pointer-events: none;
  transform: translateX(-50%);
}

#active-mode-hud.is-building {
  border-color: rgba(255, 202, 112, 0.5);
  background: rgba(30, 20, 9, 0.78);
  box-shadow:
    0 5px 20px rgba(0, 0, 0, 0.34),
    inset 0 0 18px rgba(255, 180, 68, 0.1);
}

#active-mode-icon {
  width: 96px;
  height: 96px;
  object-fit: contain;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.4));
}

#active-mode-name {
  max-width: 180px;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.94);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 11px;
  line-height: 1.2;
  text-align: center;
  text-overflow: ellipsis;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7);
  white-space: nowrap;
}

#interaction-prompt {
  position: fixed;
  z-index: 60;
  top: calc(50% + 23px);
  left: 50%;
  transform: translateX(-50%);
  padding: 5px 8px;
  border: 1px solid rgba(255, 207, 128, 0.32);
  border-radius: 5px;
  color: #ffe6b2;
  background: rgba(25, 15, 8, 0.72);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.28);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.06em;
  pointer-events: none;
  white-space: nowrap;
}

#interaction-prompt[hidden] {
  display: none;
}

#action-message {
  position: fixed;
  z-index: 65;
  top: calc(50% + 52px);
  left: 50%;
  max-width: min(520px, calc(100vw - 40px));
  transform: translateX(-50%);
  padding: 8px 13px;
  border: 1px solid rgba(203, 229, 184, 0.34);
  border-radius: 7px;
  color: #efffd9;
  background: rgba(15, 23, 17, 0.86);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.32);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1.35;
  text-align: center;
  pointer-events: none;
  animation: action-message-in 120ms ease-out;
}

#action-message.is-error {
  border-color: rgba(255, 114, 91, 0.48);
  color: #ffd0c6;
  background: rgba(45, 16, 13, 0.9);
}

#action-message.is-success {
  border-color: rgba(153, 232, 121, 0.46);
  color: #ddffc9;
}

#action-message.is-progress {
  border-color: rgba(255, 190, 91, 0.48);
  color: #ffe0a7;
  overflow: hidden;
}

#action-message.is-progress::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  width: var(--action-progress, 0%);
  height: 3px;
  content: "";
  background: #ffb84d;
  box-shadow: 0 0 8px rgba(255, 184, 77, 0.55);
  transition: width 45ms linear;
}

#action-message[hidden] {
  display: none;
}

@keyframes action-message-in {
  from {
    opacity: 0;
    transform: translate(-50%, 5px);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}
