:root {
  color-scheme: dark;
  --bg: #050806;
  --panel: rgba(11, 18, 16, 0.78);
  --panel-strong: rgba(11, 18, 16, 0.92);
  --ink: #eef7f2;
  --muted: #9eb3aa;
  --line: rgba(216, 231, 224, 0.2);
  --accent: #4fd1c5;
  --hot: #f6d365;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  overflow: hidden;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.embed .top,
body.embed .bottom,
body.embed .globe-credit {
  display: none;
}

body.embed .globe-mount {
  inset: 0;
}

button,
input {
  font: inherit;
}

.globe-app {
  position: relative;
  width: 100vw;
  height: 100vh;
}

.globe-mount {
  position: fixed;
  inset: 0;
}

.globe-mount canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.hud {
  position: fixed;
  z-index: 5;
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  backdrop-filter: blur(12px);
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.24);
}

.top {
  top: 16px;
  left: 16px;
  right: 16px;
  min-height: 78px;
  padding: 14px 16px;
}

.bottom {
  left: 16px;
  right: 16px;
  bottom: 16px;
  min-height: 74px;
  padding: 14px 16px;
  background: var(--panel-strong);
  display: grid;
  grid-template-columns: 1fr 1.3fr 1fr 1.2fr 1fr;
}

h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.1;
  letter-spacing: 0;
}

p {
  margin: 5px 0 0;
  color: var(--muted);
}

.controls {
  display: flex;
  gap: 10px;
  align-items: end;
}

label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

input,
button,
a {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink);
  padding: 0 10px;
}

button {
  background: rgba(79, 209, 197, 0.12);
}

button,
a {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  cursor: pointer;
}

button:hover,
a:hover {
  border-color: var(--accent);
}

.label {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.bottom strong {
  display: block;
  margin-top: 4px;
  font-size: 18px;
  line-height: 1.15;
}

.globe-credit {
  position: fixed;
  z-index: 5;
  right: 18px;
  bottom: 96px;
  max-width: min(460px, calc(100% - 36px));
  color: var(--muted);
  font-size: 12px;
  text-align: right;
}

@media (max-width: 720px) {
  .top,
  .bottom {
    left: 10px;
    right: 10px;
  }

  .top {
    align-items: flex-start;
    flex-direction: column;
  }

  .controls {
    width: 100%;
    flex-wrap: wrap;
  }

  label {
    flex: 1 1 190px;
  }

  .bottom {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .globe-credit {
    left: 12px;
    right: 12px;
    bottom: 196px;
    max-width: none;
    text-align: left;
    line-height: 1.25;
  }
}
