* {
  font-family: "Toss Product Sans", sans-serif;
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

.modal {
  position: fixed;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%) scale(0.95);
  width: 320px;
  max-width: 90%;
  background: #1C1C1C;
  border-radius: 20px;
  padding: 20px;
  z-index: 1000;
  opacity: 0; visibility: hidden;
  transition: opacity 0.3s ease, transform 0.3s ease;
  border: 1px solid #333;
  box-sizing: border-box;
}

.modal.show {
  opacity: 1; visibility: visible;
  transform: translate(-50%, -50%) scale(1);
}

body {
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #e0e1dd;
  background: #000000; 
}


.container {
  width: 100%;
  max-width: 400px;
  background: #101010;
  border-radius: 20px;
  padding: 35px 25px;
}


.header {
  text-align: center;
  margin-bottom: 25px;
}

.title {
  font-size: 22px;
  font-weight: 600;
  color: #f5f5f5; 
}


.amount-display {
  text-align: center;
  margin-bottom: 30px;
}

.amount {
  font-size: 48px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 5px;
}

.won {
  font-size: 18px;
  color: #777;
}


.keypad {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  margin-bottom: 30px;
}

.key {
  background: #1C1C1C;
  border: 1px solid #2A2A2A;
  font-size: 24px;
  padding: 20px;
  border-radius: 15px;
  color: #E0E1DD;
  cursor: pointer;
  transition: background-color 0.15s ease, transform 0.1s ease;
}

.key:hover {
  background: #2A2A2A;
}

.key:active {
  background: #151515;
  transform: translateY(2px);
}


.buttons {
  display: flex;
}

.action-button {
  flex: 1;
  padding: 18px;
  border: none;
  border-radius: 15px;
  font-size: 20px;
  cursor: pointer;
  font-weight: 700;
  color: #FFFFFF;
  background: #333;
  transition: background-color 0.15s ease, transform 0.1s ease;
}

.action-button:hover {
  background: #444;
}
.qr-container {
  display: flex;
  justify-content: center; 
  align-items: center;
}

.action-button:active {
  transform: translateY(1px);
  background: #2a2a2a;
}


.qr-backdrop {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.8);
  z-index: 199;
  opacity: 0; visibility: hidden;
  transition: opacity 0.3s ease;
}

.qr-backdrop.show {
  opacity: 1; visibility: visible;
}

.qr-box {
  position: fixed;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%) scale(0.95);
  width: 320px;
  max-width: 90%;
  background: #1C1C1C;
  border-radius: 20px;
  padding: 20px;
  z-index: 1000;
  opacity: 0; visibility: hidden;
  transition: opacity 0.3s ease, transform 0.3s ease;
  border: 1px solid #333;
  box-sizing: border-box;
}

.qr-box.show {
  opacity: 1; visibility: visible;
  transform: translate(-50%, -50%) scale(1);
}

.qr-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  color: #f5f5f5;
  font-size: 18px;
  font-weight: bold;
}

.qr-content {
  background: white;
  padding: 20px;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.close-btn {
  margin-left: auto;
  border: none;
  background: none;
  font-size: 28px;
  cursor: pointer;
  color: #aaa;
  transition: color 0.2s, transform 0.2s;
}

.close-btn:hover {
  color: white;
}

#qrcode {
  display: flex;
  justify-content: center;
  align-items: center;
  background: white;
  padding: 10px;
  border-radius: 8px;
}

#qrcode img {
  display: block;
  margin: 0 auto;
}

.modal-description {
  font-size: 14px;
  color: #ddd;   
  text-align: center;
  margin-bottom: 15px;
}



@keyframes shake {
  0%, 100% { transform: translateX(0); }
  10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
  20%, 40%, 60%, 80% { transform: translateX(5px); }
}

.shake {
  animation: shake 0.4s ease-in-out;
}


.ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: scale(0);
  animation: ripple-effect 0.6s linear;
  pointer-events: none;
}

@keyframes ripple-effect {
  to {
    transform: scale(4);
    opacity: 0;
  }
}

body.dark {
  background-color: #121212;
  color: #e0e0e0;
}

.container.dark {
  background-color: #1e1e1e;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.key.dark {
  background-color: #2c2c2c;
  color: #e0e0e0;
  border: none;
}

.action-button.dark {
  background-color: #424242;
  color: #ffffff;
}

.modal-content.dark {
  background-color: #2c2c2c;
  color: #e0e0e0;
}

.close-button.dark {
  color: #e0e0e0;
}