/* Base layout */

.game {
  --font: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  margin: 0;
  font-family: var(--font);
}

.game h1 {
  font-size: 28px;
  margin: 8px 0 16px;
}

/* Panels */
.game .panel {
  border-radius: 8px;
  padding: 12px 14px;
  margin: 10px 0;
  background: rgba(150,150,150,0.1);
}

/* URL mimic line */
.game #url {
  display: flex;
  align-items: center;
  font-family: var(--font);
  line-height: 1.2;
  border-radius: 10em;
  padding: 8px 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 16px;
}

.game #url:before {
  content: "🌐";
  opacity: 0.5;
  margin: 8px;
}

.game #url-text {
  white-space: pre;
  flex: 1 1 auto;
}

.game .icon-btn {
  appearance: none;
  border: 1px solid #e2e2e2;
  background: #fff;
  border-radius: 999px;
  padding: 6px 10px;
  cursor: pointer;
  line-height: 1;
}
.game .icon-btn:hover { background: #f3f3f3; }
.game .icon-btn:active { transform: translateY(1px); }

/* Instructions */
.game #instructions {
  color: #0b5;
  border: 1px solid #0b5;
}

.game #instructions:before {
  content: "ℹ️";
  padding-right: 10px;
}

/* Score */

.game .score, .game .highscore {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 1px;
}

.game #score-text {
  flex: 1 1 auto;
}

.game #score .icon-btn, .game #high-score .icon-btn {
  margin-left: auto;
}

.game .controls .icon-btn {
  width: 100%;
  padding: 12px 16px;
  font-weight: 600;
  margin-bottom: 16px;
  -webkit-tap-highlight-color: transparent;
}

.game .desktop-only {
  display: none;
}

/* Desktop: hide URL mirror where URL bar is visible */
@media (hover: hover) and (pointer: fine) {
  .game #url:before {
    content: "🌐 https://diego.horse/jump/";
  }
  .game .mobile-only, .game #url {
    display: none;
  }
  .game .desktop-only { display: flex; }
}

/* Safari desktop override: show the URL mirror even on desktop */
.safari-desktop .game #url {
  display: flex !important;
}

/* Hidden input to summon mobile keyboard */
.game .mobile-hidden-input {
  position: absolute;
  top: -1000px;
  left: -1000px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}



