* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  height: 100%;
  font-family: "Segoe UI", Arial, sans-serif;
  background: #101820;
  color: #eee;
}

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px;
  background: #1b2735;
  border-bottom: 2px solid #2c8c5c;
}

header h1 {
  margin: 0;
  font-size: 1.4rem;
}

#hud {
  display: flex;
  gap: 20px;
  font-weight: bold;
}

main {
  display: flex;
  height: calc(100vh - 58px);
}

#photoPane, #mapPane {
  flex: 1;
  position: relative;
}

#photoPane {
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

#streetPhoto {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#mapPane {
  display: flex;
  flex-direction: column;
}

#map {
  flex: 1;
}

#guessBtn {
  padding: 14px;
  font-size: 1.1rem;
  font-weight: bold;
  border: none;
  background: #2c8c5c;
  color: white;
  cursor: pointer;
}

#guessBtn:disabled {
  background: #555;
  cursor: not-allowed;
}

#guessBtn:not(:disabled):hover {
  background: #37a86f;
}

.hidden {
  display: none !important;
}

#resultOverlay, #finalOverlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

#resultBox, #finalBox {
  background: #1b2735;
  padding: 30px 40px;
  border-radius: 10px;
  text-align: center;
  border: 2px solid #2c8c5c;
  min-width: 300px;
}

#resultBox h2, #finalBox h2 {
  margin-top: 0;
  color: #37a86f;
}

#resultBox p, #finalBox p {
  font-size: 1.1rem;
}

#resultBox button, #finalBox button {
  margin-top: 15px;
  padding: 10px 24px;
  font-size: 1rem;
  font-weight: bold;
  border: none;
  border-radius: 6px;
  background: #2c8c5c;
  color: white;
  cursor: pointer;
}

#resultBox button:hover, #finalBox button:hover {
  background: #37a86f;
}

.actual-marker {
  font-size: 22px;
  text-align: center;
  line-height: 24px;
}

@media (max-width: 800px) {
  main {
    flex-direction: column;
    height: auto;
  }
  #photoPane, #mapPane {
    height: 50vh;
  }
}
