* {
  box-sizing: border-box;
  font-family: Arial, sans-serif;
}

body {
  margin: 0;
  background: #0f172a;
  color: #fff;
}

.app {
  max-width: 420px;
  margin: auto;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

header {
  padding: 16px;
  text-align: center;
  background: #020617;
}

header p {
  color: #22c55e;
  font-weight: bold;
}

.balance-box {
  margin-top: 8px;
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  padding: 6px 14px;
  background: #020617;
  border: 1px solid #1e293b;
  border-radius: 12px;
}

.balance-amount {
  font-size: 26px;
  font-weight: bold;
  color: #22c55e;
}

.balance-unit {
  font-size: 14px;
  color: #94a3b8;
}

main {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

#coin {
  position: relative;
  width: 220px;
  height: 220px;
  cursor: pointer;
}

.coin-bg {
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

.coin-avatar {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 120px;
  height: 120px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
}

#coin:active {
  transform: scale(0.95);
}

#tap-area {
  text-align: center;
  cursor: pointer;
}

#tap-area img {
  width: 200px;
  border-radius: 50%;
  transition: transform 0.1s;
}

#tap-area:active img {
  transform: scale(0.95);
}

.tap-float {
  position: absolute;
  color: #22c55e;
  font-weight: bold;
  animation: floatUp 0.8s ease-out forwards;
  pointer-events: none;
}

.floating-plus {
  position: absolute;
  font-size: 20px;
  font-weight: bold;
  color: gold;
  pointer-events: none;
  animation: floatUp 0.8s ease-out forwards;
}

@keyframes floatUp {
  0% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(-50px);
  }
}


footer {
  padding: 12px;
  background: #020617;
}

.energy {
  text-align: center;
  margin-bottom: 8px;
}

.energy-bar {
  margin-top: 6px;
  width: 100%;
  height: 8px;
  background: #1e293b;
  border-radius: 6px;
  overflow: hidden;
}

.energy-fill {
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, #22c55e, #4ade80);
  transition: width 0.3s ease;
}


.buttons {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

button {
  padding: 10px;
  background: #1e293b;
  border: none;
  color: white;
  border-radius: 8px;
}
