@import url("https://fonts.googleapis.com/css2?family=Press+Start+2P&family=VT323&display=swap");

:root {
  --primary-color: #ffcc00;
  --accent-color: #ff006e;
  --surface-color: #242424;
  --surface-alt-color: #313131;
  --text-color: #ffffff;
  --success-color: #4caf50;
  --error-color: #f44336;
}

* {
  box-sizing: border-box;
  scrollbar-width: thin;
  scrollbar-color: var(--accent-color) var(--surface-alt-color);
}

html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  font-family: "Press Start 2P", "VT323", monospace, sans-serif;
  background:
    radial-gradient(circle at 50% 0%, #2e004d 0%, #10001b 60%) fixed,
    #0c0c0c
      url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 10 10' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 0h10v10H0z' fill='%23131313'/%3E%3Cpath d='M0 0h5v5H0z' fill='%23222222'/%3E%3Cpath d='M5 5h5v5H5z' fill='%23222222'/%3E%3C/svg%3E")
      repeat fixed;
  color: var(--text-color);
  letter-spacing: 0.5px;
  line-height: 1.2;
  text-shadow: 1px 1px 0 #000;
}

.app-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  min-height: 100%;
  padding: 2rem 1rem 4rem;
}

.container {
  width: 100%;
  max-width: 28rem;
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

.send-receive-buttons {
  display: flex;
  gap: 0.75rem;
  margin: 1rem 0 1.5rem;
  justify-content: space-between;
}

.retro-card {
  position: relative;
  background: linear-gradient(180deg, #2f2f2f 0%, #1d1d1d 75%);
  border: 3px solid var(--accent-color);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  box-shadow:
    0 0 0 4px #000,
    0 0 0 8px var(--primary-color);
}

.retro-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 4px;
  padding: 2px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.12), transparent);
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.retro-btn {
  position: relative;
  display: inline-block;
  font-family: "Press Start 2P", monospace;
  font-size: 0.8rem;
  padding: 0.65rem 1.25rem;
  cursor: pointer;
  color: var(--text-color);
  border: 3px solid var(--accent-color);
  border-radius: 4px;
  background: linear-gradient(
    145deg,
    var(--surface-alt-color) 0%,
    #1a1a1a 100%
  );
  box-shadow: 4px 4px 0 #000;
  text-transform: uppercase;
  transition:
    transform 0.1s ease,
    filter 0.15s ease;
  overflow: hidden;
}

.retro-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 50%;
  background: rgba(255, 255, 255, 0.06);
  transform: translateY(-100%);
  pointer-events: none;
  transition: transform 0.3s ease;
}

.retro-btn:hover::before {
  transform: translateY(0%);
}

.retro-btn:hover {
  filter: brightness(1.15);
}

.retro-btn.primary {
  background: linear-gradient(145deg, var(--primary-color) 0%, #d4af00 100%);
  color: #000;
}

.retro-btn.danger {
  background: linear-gradient(145deg, var(--error-color) 0%, #a83226 100%);
}

.retro-btn:active {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 #000;
}

dialog {
  position: relative;
  background: var(--surface-color);
  outline: none;
  width: 100%;
  max-width: clamp(450px, 80vw, 650px);
  max-height: 60vh;
  border: 3px solid var(--accent-color);
  border-radius: 8px;
  box-shadow:
    0 0 0 4px #000,
    0 0 0 8px var(--primary-color);
  font-family: "Press Start 2P", monospace;
  color: var(--text-color);
  padding: 2rem 2.5rem;
}

dialog::backdrop {
  background: rgba(0, 0, 0, 0.8);
}

*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

*::-webkit-scrollbar-track {
  background: var(--surface-alt-color);
}

*::-webkit-scrollbar-thumb {
  background-color: var(--accent-color);
  border: 2px solid #000;
  border-radius: 8px;
}

*::-webkit-scrollbar-thumb:hover {
  background-color: var(--primary-color);
}

*::-webkit-scrollbar-corner {
  background: var(--surface-alt-color);
}

.retro-input {
  font-family: "Press Start 2P", monospace;
  font-size: 0.8rem;
  padding: 0.65rem 1.25rem;
  color: var(--text-color);
  background: linear-gradient(
    145deg,
    var(--surface-alt-color) 0%,
    #1a1a1a 100%
  );
  border: 3px solid var(--accent-color);
  border-radius: 4px;
  box-shadow: 4px 4px 0 #000;
  transition: filter 0.15s ease;
}

.retro-input:focus {
  outline: none;
  filter: brightness(1.15);
}

.retro-input:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.retro-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  filter: none;
}

.retro-btn:disabled:hover {
  filter: none;
  transform: none;
}
