/* === Roaring Pepe Arcade CSS: Mobile-First with Desktop/Tablet at 786px === */

/* ---------- BASE RESET & NORMALIZATION ---------- */
*, *::before, *::after {
  box-sizing: border-box;
}
body, h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd, ul, ol, pre, form, fieldset, legend {
  margin: 0;
  padding: 0;
}
ul, ol, menu {
  list-style: none;
}
html, body {
  max-width: 100vw;
  height: 100%;           /* Already present */
  border: 0;
  font-family: 'Press Start 2P', sans-serif;
  font-size: 16px;
  background: #4C933F;
  color: #fff;
  font-display: swap;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

img, picture, video, canvas, svg {
  display: block;
  margin: auto;
  -webkit-user-drag: none;
  user-drag: none;
  -webkit-touch-callout: none;
}
input, button, textarea, select {
  font: inherit;
  background: none;
  border: none;
  outline: none;
  color: inherit;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  transition: background-color 100000s;
  -webkit-transition: background-color 100000s;
}
button {
  cursor: pointer;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}
a {
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  background-color: transparent;
  -webkit-tap-highlight-color: transparent;
  -moz-tap-highlight-color: transparent;
}
button, a {
  -webkit-tap-highlight-color: transparent;
  -moz-tap-highlight-color: transparent;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  touch-action: manipulation;
}
p {
  margin-bottom: 1em;
}
textarea {
  resize: vertical;
}
button:disabled, input:disabled, textarea:disabled, select:disabled {
  cursor: not-allowed;
  opacity: 0.6;
  outline: none;
}
.skip-link {
  position: absolute;
  left: -999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
  z-index: 99999;
  background: #ffd900;
  color: #183c14;
  font-weight: bold;
  padding: 0.5em 1em;
  border-radius: 6px;
}
.skip-link:focus {
  left: 50%;
  top: 12px;
  width: auto;
  height: auto;
  transform: translateX(-50%);
  outline: 2px solid #183c14;
}
:focus-visible {
  outline: 2px solid #ffd900;
  outline-offset: 2px;
}
html {
  scroll-behavior: smooth;
  -webkit-scroll-behavior: smooth;
}

/* ---------- MOBILE-FIRST: ARCADE SITE STYLES ---------- */

/* Header/nav: stacked nav links, compact header */
.arcade-header {
  display: flex;
  flex-direction: column;
  justify-items: center;
  align-items: center;
  text-align: center;
}
.arcade-header h1 {
  margin: 1rem auto 0 auto;
  font-size: 1.1rem;
  letter-spacing: 2.5px;
  text-shadow: 0 0 10px #ffd900, 2px 2px 0 #183c14, 0 0 25px #fff60f55;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 0.3rem;
  margin: 0;
  animation: header-glow 1.8s infinite alternate cubic-bezier(.66,.04,.35,1.09);
}
@keyframes header-glow {
  0% { text-shadow: 0 0 10px #ffd900, 2px 2px 0 #183c14, 0 0 25px #fff60f55; }
  100% { text-shadow: 0 0 18px #fff60f, 4px 4px 0 #183c14, 0 0 60px #20c964; }
}
.arcade-header-top {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.6em;
  margin-bottom: 0.2em;
}
.arcade-header-top .pixel-logo-mobile img {
  width: 52px;
  height: 52px;
}
.arcade-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  width: 100%;
  height: 6em;
  padding: 1em;
  gap: 1em;
}
.arcade-header-left {
  display: flex;
  justify-content: left;
  gap: 0.5em;
}
.arcade-header-right {
  display: flex;
  justify-content: right;
  gap: 0.5em;
}
.arcade-header-middle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4em;
  min-width: 150px;
  margin: 0 0.2em;
  font-size: 1em;
}
.arcade-header-left,
.arcade-header-right,
.arcade-header-middle {
  width: 220px;
  min-width: 160px;
  max-width: 280px;
}
.arcade-header-bottom {
  font-size: 0.75em;
}
.arcade-header-bottom .header-copy {
  display: none;
}
.arcade-header-bottom a:hover {
  flex: 1 0 auto;
  text-decoration: underline;
  color: #ffd900;
}

.monthly-label {
  color: #ffd900;
  font-family: 'Press Start 2P', monospace;
  font-size: 0.95em;
  text-shadow: 0 0 8px #23411488, 2px 2px 0 #183c14;
  display: flex;
  align-items: center;
}
.monthly-label img {
  margin-left: 0.5em;
  width: 30px;
  height: 30px;
}

#monthly-points {
  min-width: 2.5em;
  font-size: 1.5em;
  margin-left: 1em;
  background: linear-gradient(135deg, #ffed85 60%, #fff9d6 100%);
  color: #234114;
  border-color: #ffd900;
}
h3 {
  font-size: 1.5em;
}
.pixel-logo-mobile {
  display: flex;
  justify-content: center;
  align-items: center;
}
.pixel-logo-mobile img {
  width: 56px;
  height: 56px;
}

.pixel-logo-desktop {
  display: none;
}
.arcade-header nav a {
  color: #fff;
  text-decoration: none;
  font-size: 0.98rem;
  border: 2px solid #ffd900;
  background: #183c14;
  border-radius: 8px;
  padding: 0.55rem 0.7rem;
  margin-bottom: 0.2rem;
  font-family: inherit;
  box-shadow: 0 3px #20c96488;
  transition: background 0.17s, box-shadow 0.19s, color 0.19s;
  text-shadow: 1px 1px #183c14;
  letter-spacing: 1px;
  width: 100%;
  box-sizing: border-box;
  text-align: center;
}
/* HUD */

.arcade-hud {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(135deg, #222b25 80%, #1c2422 100%);
  border-bottom: 2px solid #183c14;
  align-self: stretch;
  box-shadow: 2px 2px 0 #0007;
  margin-bottom: 0.5em;
  min-height: 38px;
  font-family: 'Press Start 2P', monospace, sans-serif;
  font-size: 1.2em;
  line-height: 1;
  padding-top: 0;
  padding-bottom: 0;
}

.hud-item {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  padding: 1em 0;
  height: 3em;
  font-size: 1.4em;
  transition: background 0.2s, box-shadow 0.2s, border 0.2s;
  background: linear-gradient(180deg, #2a322a 0%, #1c241f 100%);
  align-items: center;
  border-top: 2px solid #3d4d3f;   /* light top */
  border-left: 2px solid #3d4d3f;  /* light left */
  border-bottom: 2px solid #0f140f; /* dark bottom */
  border-right: 2px solid #0f140f; /* dark right */
  box-shadow: inset 0 0 0 1px #1a1f1a;
}

.hud-item:hover, .hud-item-active {
  background: linear-gradient(180deg, #1a201a 0%, #121712 100%);
  border-top: 2px solid #0f140f;   /* pressed */
  border-left: 2px solid #0f140f;
  border-bottom: 2px solid #3d4d3f; /* pressed shadow flipped */
  border-right: 2px solid #3d4d3f;
  box-shadow: inset 0 2px 4px #000;
  background: #183c14;
  box-shadow: inset 0 2px 4px #000;
}

.hud-item img {
  width: 18px;
  height: 18px;
  image-rendering: pixelated;
  margin: 0;
  display: block;
}

#hud-user-icon {
  display: none;
}

.hud-item * {
  line-height: 1;
}

.hud-menu-btn {
  all: unset;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

#menu-open-btn, #hud-profile-btn {
  cursor: pointer;
}

.hud-divider {
  width: 2px;
  flex-shrink: 0;
  background: linear-gradient(to bottom, #3d4d3f, #0f140f);
}

#hud-user {
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.2s;
}
#hud-user.visible {
  visibility: visible;
  opacity: 1;
}

#hud-wallet-btn, #hud-status {
  display: none;
}

#hud-address-icon {
  padding-top: 4px;
  display: inline-block;
}
#hud-address-icon img {
  width: 28px;
  height: 28px;
}

#hud-address {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 160px;
  display: inline-block;
  vertical-align: bottom;
}

/* HORIZONTAL STATS CONTAINER */
.arcade-badges {
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  margin-top: 0.4em;
  margin-bottom: 0.8em;
  padding: 0;
  width: 100%;
  max-width: 100%;
  /* background: linear-gradient(135deg, #ffd900 60%, #f6ffd6 100%); */
  background: linear-gradient(135deg, #c9df54 60%, #ffd900 100%);
  color: #35692b;
  font-family: 'Press Start 2P', monospace, sans-serif;
  font-size: 1em;
  font-weight: 600;
  letter-spacing: 1px;
  padding: 0.58em 1.1em 0.49em 1.1em;
  clip-path: polygon(
    0 0, 6px 0, 6px 6px, 0 6px,
    0 calc(100% - 6px), 6px calc(100% - 6px), 6px 100%,
    calc(100% - 6px) 100%, calc(100% - 6px) calc(100% - 6px), 100% calc(100% - 6px),
    100% 6px, calc(100% - 6px) 6px, calc(100% - 6px) 0, 0 0
  );
  border: 2px solid #274c10;
  box-shadow: 2px 3px 0 #b5ba58;
}

.arcade-badge {
  /* background: linear-gradient(135deg, #c9df54 60%, #ffd900 100%); */
  display: flex;
  flex-direction: row;
  text-align: center;
  align-items: center;
  margin: 0;
  color: #183c14;
}

.badge-attempts {
  margin-right: auto;
  justify-self: flex-start;
}

.badge-points {
  margin-left: auto;
  justify-self: flex-end;
}

.arcade-badge img {
  width: 32px;
  height: 32px;
}

.arcade-horizontal-badges {
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 18px;
  margin: 0.5em 0 1.1em 0;
  width: 100%;
}

.arcade-badge.stat-horizontal {
  /* Side badges */
  min-width: 160px;
  max-width: 180px;
  flex: 0 0 170px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.32em;
  border-radius: 8px;
  font-family: 'Press Start 2P', monospace, sans-serif;
  box-shadow: 2px 3px 0 #b5ba58;
  margin: 0;
  padding: 0.1em 0.6em;
}

/* The main score badge fills remaining space, is two rows, centered */
.arcade-badge.badge-score {
  flex: 1 1 0;
  min-width: 340px;
  max-width: 600px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  height: 66px;
  padding: 0.1em 1em 0.1em 1em;
  background: linear-gradient(135deg, #c9df54 60%, #ffd900 100%);
  position: relative;
}

.stat-score-title {
  font-size: 1.2em;
  font-weight: bold;
  color: #274c10;
  letter-spacing: 1px;
  line-height: 1.1;
  margin-bottom: 0.11em;
  text-shadow: 1px 1px 0 #ffd90033;
  font-family: 'Press Start 2P', monospace, sans-serif;
}

.stat-score-values {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.7em;
  font-size: 1.17em;
}

.stat-label {
  color: #ffd900;
  font-weight: bold;
  text-shadow: 2px 2px 2px #183c14, 0 0 5px #fff9;
}

.stat-value {
  color: #183c14;
  font-weight: bold;
  margin-left: 0.13em;
  margin-right: 0.22em;
  letter-spacing: 0.7px;
}

.stat-divider {
  color: #b5ba58;
  font-weight: bold;
  font-size: 0.92em;
}

.badge-rank {
  background: linear-gradient(135deg, #ffd900 90%, #fff97c 100%);
  color: #183c14;
  border: 2px solid #ffd900;
}

.badge-rank .stat-value {
  color: #fff;
  background: #183c14;
  border-radius: 5px;
  padding: 0.1em 0.38em;
  margin-left: 0.15em;
  box-shadow: 0 2px 0 #b5ba58;
}

@media (max-width: 700px) {
  .arcade-horizontal-badges {
    flex-direction: column;
    gap: 10px;
    align-items: stretch;
  }
  .arcade-badge.stat-horizontal, .arcade-badge.badge-score {
    min-width: 0;
    max-width: 100vw;
    width: 100%;
  }
}

/* MENU */

.arcade-dropdown {
  display: none;
  position: absolute;
  right: 0;
  top: 40px;
  font-size: 3em;
  z-index: 999;
  background: linear-gradient(135deg, #222b25 80%, #1c2422 100%);
  border: 2px solid #183c14;
  box-shadow: 2px 2px 0 #0007;
  min-width: 170px;
  width: 100%;
  box-shadow: 0 4px 24px #274c1066;
  padding: 0.7em 0.2em 0.7em 0.2em;
}
.arcade-dropdown.open {
  display: block;
}
.arcade-dropdown li {
  list-style: none;
  margin: 0.2em 0;
}
.arcade-dropdown a {
  display: block;
  padding: 0.5em 1.2em;
  font-family: inherit;
  color: #f6ffd6;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.13s;
}
.arcade-dropdown a:hover {
  background: #f6ffd6;
  color: #234114;
}

/* Copy-to-clipboard box for code or shareable content */

.copy-to-cb {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  background: linear-gradient(90deg, #293e23 80%, #345f29 100%);
  border: 0;
  box-shadow:
    0 0 0 4px #244c15,         /* main dark border */
    2px 3px 0 #b5ba58,         /* yellow-green shadow */
    0 0 0 7px #183c14;         /* outer shadow, dark green */
  border-radius: 0;
  color: #e2ff87;
  padding: 1.05em 1.3em 1.01em 1.3em;
  margin: 2.3em 0;
  font-family: 'Press Start 2P', monospace, sans-serif;
  font-size: 1.01em;
  line-height: 1.8;
  letter-spacing: 0.9px;
  word-break: break-all;
  position: relative;
  cursor: pointer;
  user-select: all;
  transition: background 0.16s, box-shadow 0.14s, color 0.14s;
  /* Pixelated scanlines */
  background-image:
    repeating-linear-gradient(to bottom, transparent, transparent 11px, #21381618 12px, transparent 13px);
  background: linear-gradient(90deg, #387340 80%, #52b94c 100%);
  clip-path: polygon(
    0 0, 10px 0, 10px 10px, 0 10px,
    0 calc(100% - 10px), 10px calc(100% - 10px), 10px 100%,
    calc(100% - 10px) 100%, calc(100% - 10px) calc(100% - 10px), 100% calc(100% - 10px),
    100% 10px, calc(100% - 10px) 10px, calc(100% - 10px) 0, 0 0
  );
}

.copy-to-cb:hover,
.copy-to-cb.copied {
  box-shadow:
    0 0 0 4px #ffd900,
    2px 4px 0 #f9ff90cc,
    0 0 0 7px #183c14;
  color: #fffde6;
}

.copy-to-cb::after {
  content: attr(data-cb-label);
  position: absolute;
  right: 3em;
  color: #ffd900;
  background: #244c15d9;
  padding: 0.22em 0.9em;
  border-radius: 4px;
  font-size: 0.79em;
  font-family: inherit;
  opacity: 0.87;
  pointer-events: none;
  transition: opacity 0.14s, background 0.13s;
  font-family: 'Press Start 2P', monospace, sans-serif;
  letter-spacing: 1px;
  box-shadow: 2px 2px 0 #183c14;
}

.copy-to-cb.copied::after {
  content: "Copied!";
  color: #234114;
  background: #ffe800f6;
  opacity: 1;
  font-weight: bold;
  text-shadow: 1px 1px 0 #ffd90044;
  box-shadow: 2px 2px 0 #ffd90044;
}

@media (max-width: 600px) {
}

/* Arcade Rules 3.0 */
.content-card {
  background: linear-gradient(120deg, #35692b 80%, #357333 120%);
  color: #fff;
  margin: 3em auto 2em auto;
  border-radius: 14px;
  padding: 2.4em 2.2em 2.4em 2.2em;
  max-width: 800px;
  box-shadow: 0 0 0 4px #274c10, 0 4px 28px #0008;
  position: relative;
  overflow: hidden;
  font-size: 1.09em;
  line-height: 1.8;
  letter-spacing: 0.02em;
}

@media (max-width: 700px) {
  .content-card {
    padding: 1.2em 0.6em;
    margin: 1.5em 0.2em;
    font-size: 0.99em;
  }
}

.content-card h1, .content-card h2, .content-card h3 {
  margin-top: 0;
  margin-bottom: 1.2em;
  color: #ffd900;
  text-shadow: 0 2px 8px #234114, 0 0 14px #fff60f66;
  font-family: 'Press Start 2P', monospace, sans-serif;
  letter-spacing: 2px;
  line-height: 1.22;
}
.content-card h2 {
  font-size: 1.33em;
  color: #ffe800;
  text-shadow: 0 2px 10px #183c14, 0 0 5px #ffd90077;
  margin-bottom: 0.8em;
  text-transform: uppercase;
  letter-spacing: 2.3px;
  font-weight: bold;
}

.content-card h3 {
  font-size: 1.08em;
  color: #b5ec61;
  text-shadow: 0 1px 4px #274c1099;
  margin-top: 1.3em;
  margin-bottom: 0.5em;
  text-transform: none;
  letter-spacing: 1.1px;
  font-weight: normal;
}
.content-card ul,
.content-card ol {
  padding-left: 0.5em;
  font-size: 1em;
}
.content-card li {
  margin-bottom: 1em;
  padding-left: 0.2em;
}
.content-card table {
  width: 100%;
  margin: 2em 0;
  border-collapse: separate;
  border-spacing: 0;
  background: rgba(30, 40, 30, 0.98);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 16px #0003;
}
.content-card th, .content-card td {
  padding: 1em 1.1em;
  text-align: left;
  border-bottom: 1px solid #274c10;
  font-size: 1em;
}
.content-card th {
  background: #274c10;
  color: #ffd900;
  font-weight: bold;
  text-shadow: 0 1px 3px #183c14;
}
.content-card tr:last-child td {
  border-bottom: none;
}

.contract-address {
  font-size: 0.6em;
}

/* Arcade Info Steps */
.info-steps-block {
  background: #295c23;
  border: 3px solid #183c14;
  border-radius: 22px;
  padding: 1.6em 1.2em;
  max-width: 540px;
  margin: 2em auto;
  box-shadow: 0 1px 18px #21330b60;
  font-family: 'Press Start 2P', monospace, sans-serif;
  color: #fff;
  font-size: 1.15em;
}
.info-steps-title {
  display: flex;
  align-items: center;
  font-size: 1.25em;
  color: #ffd900;
  letter-spacing: 1px;
  font-weight: bold;
  margin-bottom: 1.3em;
  gap: 0.5em;
}
.info-steps-icon {
  width: 1.5em; height: 1.5em; vertical-align: -0.25em; display: inline-block; margin-right: 0.25em;
}
.info-steps-list {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1em;
}
.info-steps-list li {
  display: flex;
  flex-direction: row;
  align-items: center;
  background: #30742a;
  border: 1.5px solid #183c14;
  border-radius: 10px;
  padding: 0.75em 0.85em;
  gap: 1.2em;
}
.info-steps-icon-col {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3em;
  min-width: 3em;
  height: 3em;
}
.info-steps-icon-col img {
  width: 2.2em;
  height: 2.2em;
  display: block;
  margin: auto;
  filter: drop-shadow(0 0 3px #0004);
}
.info-steps-text-col {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.15em;
}
.info-steps-step-title {
  font-weight: bold;
  color: #ffe956;
  font-size: 1.07em;
  letter-spacing: 0.5px;
  display: block;
  line-height: 1.25;
}
.info-steps-step-note {
  display: block;
  color: #b4ed74;
  font-size: 0.96em;
  margin-top: 0.10em;
  font-weight: normal;
  line-height: 1.22;
}
@media (max-width: 600px) {
  .info-steps-block {
    padding: 1em 0.6em;
    font-size: 1em;
  }
  .info-steps-title {
    font-size: 1em;
  }
  .info-steps-list li {
    gap: 0.8em;
    padding: 0.5em 0.3em;
  }
  .info-steps-icon-col {
    width: 2.2em;
    min-width: 2.2em;
    height: 2.2em;
  }
  .info-steps-icon-col img {
    width: 1.6em; height: 1.6em;
  }
}

.icon-legend img {
  width: 40px;
  height: 40px;
}

.info-list-block {
  margin: 1.6em 0 0 0;
  padding: 0;
  list-style: none;
  z-index: 1;
  position: relative;
}

.info-list-block li {
  font-family: inherit;
  color: #fff;
  margin: 0 0 1.18em 0;
  padding-left: 2.6em;
  position: relative;
  line-height: 1.6;
  letter-spacing: 1.1px;
  background: none;
}
.info-list-block li::before {
  content: "";
  display: inline-block;
  width: 1.25em;
  height: 1.25em;
  margin-right: 0.7em;
  position: absolute;
  left: 0;
  top: 0.13em;
  box-shadow:
    2.5px 3.5px 0 #b5ba58,   /* bottom-right shadow */
    0 1.5px 0 #fff8,         /* top highlight */
    0 0 0 2px #274c10;       /* border */
  /* subtle pixel border effect */
  background-blend-mode: multiply;
  /* optional shine */
  /* add an overlay shine for extra arcade */
  /* You can add a highlight via ::after if you want more polish */
}

/* Wallet */
.profile-mobile {
  display: block;
  margin-top: 0.6em;
  padding-top: 0.7em;
  border-top: 1px solid #ffd90066;
  text-align: right;
}
.profile-mobile .profile-username {
  font-weight: bold;
  font-size: 1.06em;
  color: #ffd900;
  margin-bottom: 0.2em;
  word-break: break-all;
}

/* --- Wallet Area --- */

/* Status */
#wallet-area #status, #status-ellipses {
  display: none;
  color: #fff;
  font-family: 'Press Start 2P', monospace, sans-serif;
  font-size: 0.6em;
  letter-spacing: 0.5px;
}

/* Wallet address chip */
#wallet-area {
  display: block;
  font-family: "Menlo", "Consolas", monospace;
  color: #234114;
  padding: 0.26em 0.74em;
  font-weight: bold;
  font-size: 1em;
  transition: background 0.18s, color 0.18s, box-shadow 0.15s;
}

#wallet-address {
  font-size: 1em;
  padding: 0.5em;
}

/* ---------- Games grid & cards ---------- */
.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(0, 240px));
  gap: 1.1rem;
  justify-content: center;
  padding: 0 0.5em;
  width: 100%;
  box-sizing: border-box;
  margin-top: 2em;
}
.game-card {
  background: linear-gradient(135deg, #397e36 80%, #25481e 100%);
  margin: 6px;
  border-top: 4px solid #274c10;      /* medium-dark green (top "light") */
  border-left: 4px solid #274c10;     /* medium-dark green (left "light") */
  border-bottom: 4px solid #11240c;   /* darkest green (bottom shadow) */
  border-right: 4px solid #11240c;    /* darkest green (right shadow) */
  border-radius: 0;
  position: relative;
  overflow: visible;
}

/* "Pressed" effect: double-thick outline and pressed-in shadow */
.game-card:hover,
.game-card:focus-within {
 border-top: 4px solid #11240c;      /* darkest green now on top */
  border-left: 4px solid #11240c;     /* darkest green now on left */
  border-bottom: 4px solid #274c10;   /* lighter green now on bottom */
  border-right: 4px solid #274c10;    /* lighter green now on right */
  box-shadow: 0  0 24px #000a;
}
.game-card img {
  width: 50%;
  image-rendering: pixelated;
}
.game-card::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255,255,255,0.06),
    rgba(255,255,255,0.06) 2px,
    transparent 2px,
    transparent 6px
  );
  opacity: 0.5;
  background-position-y: 0;
  transition:
    opacity 0.18s,
    background-position-y 0.7s cubic-bezier(.32,.1,.48,1.21);
}
.game-card:hover::before,
.game-card:focus-within::before {
  opacity: 0.8;
  background-position-y: 16px;
}
@keyframes scanline-move {
  0% { background-position-y: 0; }
  100% { background-position-y: 16px; }
}
.game-card:hover::before,
.game-card:focus-within::before {
  opacity: 0.8;
  animation: scanline-move 0.8s linear infinite;
}
.game-content {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0.7rem 0.5rem 0.8rem 0.5rem;
  background: rgba(28, 60, 20, 0.80);
  box-shadow: 0 -4px 0 #183c14;
  text-align: center;
}
.game-title {
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
  word-break: break-word;
}
.game-desc {
  font-size: 0.95rem;
  margin-bottom: 1rem;
  word-break: break-word;
}
.game-play-btn {
  background: linear-gradient(135deg, #c9df54 60%, #ffd900 100%);
  color: #35692b;
  font-family: 'Press Start 2P', monospace, sans-serif;
  font-size: 1em;
  font-weight: 600;
  letter-spacing: 1px;
  padding: 0.58em 1.1em 0.49em 1.1em;
  clip-path: polygon(
    0 0, 6px 0, 6px 6px, 0 6px,
    0 calc(100% - 6px), 6px calc(100% - 6px), 6px 100%,
    calc(100% - 6px) 100%, calc(100% - 6px) calc(100% - 6px), 100% calc(100% - 6px),
    100% 6px, calc(100% - 6px) 6px, calc(100% - 6px) 0, 0 0
  );
  border: 2px solid #274c10;
  box-shadow: 2px 3px 0 #b5ba58;
}
.game-card:hover .game-play-btn,
.game-card:focus-within .game-play-btn {
  background: linear-gradient(135deg, #fffde0 70%, #ffe800 100%);
  color: #35692b;
  box-shadow: 0 8px 24px #ffd900cc, 0 0 6px #20c96477;
}
.game-play-btn2 {
  display: block;
  max-width: 325px;
  width: 100%;
  font-family: inherit;
  background: #ffd900;
  color: #183c14;
  border: 2px solid #fff;
  font-size: 1rem;
  padding: 0.5rem 0;
  border-radius: 6px;
  cursor: pointer;
  box-shadow: 0 2px #20c964;
  transition: background 0.15s, color 0.15s, box-shadow 0.14s;
  margin-top: 0.5rem;
  font-weight: bold;
  letter-spacing: 2px;
  text-align: center;
  text-decoration: none;
}
.game-play-btn2:hover, .game-play-btn2:focus {
  background: #fff;
  color: #183c14;
  box-shadow: 0 4px #20c964;
  border: 2px solid #ffd900;
  outline: 2px solid #ffd900;
}

/* GAME CONSOLE */

#game-console {
  position: relative;
  width: 100%;
  display: flex;
  min-height: 450px;
}
.game-container {
  display: none;
  padding-bottom: 2em;
}
#start-game-btn {
  display: none;
}
.pregame-container {
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.pregame-container h2 {
  width: 100%;
  text-align: center;
  margin-bottom: 1.2em;
}
.pregame-container div {
  display: inline-block;
}
.info-list-loading-indicator {
  display: flex;
  width: 100%;
  justify-content: center;
  align-items: center;
  text-align: center;
  margin-top: 1.2em;
  color: #ffb800;
}  
.in-game-notification {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 40px;
  text-align: center;
}

.game-loading {
  display: none;
  z-index: 1000;
  inset: 0;
  flex-direction: column;
  align-items: center;
  min-height: 120px;
  justify-content: center;
  pointer-events: all;
}

/* LOADING Text */
.game-loading::before {
  content: "LOADING...";
  display: block;
  text-align: center;
  font-family: 'Press Start 2P', monospace, sans-serif;
  color: #ffd900;
  letter-spacing: 1px;
  margin-bottom: 2.2em;
  text-shadow: 0 2px #274c10, 0 0 8px #ffd90033;
  font-size: 1.1em;
}

/* Static bar background */
.loading-bar {
  width: 52vw;
  max-width: 340px;
  min-width: 90px;
  height: 2.2em;
  background:
    repeating-linear-gradient(
      to right,
      #1a3913 0 14px,
      #274c10 14px 16px
    );
  border: 3px solid #274c10;
  border-radius: 0;
  box-shadow: 0 0 0 4px #183c14, 0 0 12px #000b;
  position: relative;
  overflow: hidden;
}

/* The animated "filling" bar */
.loading-bar::after {
  content: "";
  display: block;
  position: absolute;
  top: 0; left: 0; bottom: 0;
  width: 30%;
  background:
    repeating-linear-gradient(
      to right,
      #ffd900 0 10px,
      #c9df54 10px 18px,
      #ffd900 18px 30px
    );
  box-shadow: 0 0 10px #ffd90088;
  animation: loading-bar-infinite 1.25s cubic-bezier(.68,0,.52,1.12) infinite;
}

@keyframes loading-bar-infinite {
  0% { left: 0; width: 0%; opacity: 1; }
  10% { left: 0; width: 16%; opacity: 1; }
  40% { left: 0; width: 100%; opacity: 1; }
  80% { left: 90%; width: 10%; opacity: 1; }
  100% { left: 100%; width: 0%; opacity: 0.7; }
}

/* Responsive for small screens */
@media (max-width: 600px) {
  .loading-bar {
    width: 86vw;
    min-width: 60px;
    height: 1.3em;
  }
  .game-loading::before {
    font-size: 1em;
    margin-bottom: 1.3em;
  }
}

/* ARCADE INPUT */

.arcade-terminal-container {
  display: flex;
  flex-direction: column;
  background: #222a21;
  border: 2px solid #314e29;
  border-radius: 12px;
  box-shadow: 0 4px 24px #051f0870;
  padding: 2.2em 2em 1.2em 1.8em;
  max-width: 420px;
  font-family: 'Press Start 2P', monospace, sans-serif;
  color: #c9df54;
  position: relative;
}

.arcade-terminal-output {
  color: #8bc47e;
  font-size: 0.9em;
  margin-bottom: 1.3em;
  opacity: 0.85;
  letter-spacing: 1px;
  text-shadow: 0 0 2px #bfdc9c2c;
}

.arcade-terminal-line {
  display: flex;
  align-items: center;
  font-size: 1.02em;
}

.arcade-prompt {
  color: #ffd900;
  margin-right: 0.5em;
  font-weight: bold;
  font-size: 1em;
  text-shadow: 1px 1px 0 #274c10, 0 0 2px #ffd90080;
}

.arcade-input-terminal {
  background: transparent;
  border: none;
  border-bottom: 2px solid #ffd900;
  color: #f8fff2;
  font-family: inherit;
  font-size: inherit;
  outline: none;
  padding: 0.2em 0.4em 0.2em 0.1em;
  margin-right: 0.3em;
  min-width: 11ch;
  max-width: 320px;
  letter-spacing: 1px;
  box-shadow: none;
  caret-color: #ffd900;
  transition: border-color 0.2s;
}

.arcade-input-terminal:focus {
  border-bottom-color: #20c964;
  background: #223d1c;
}

.arcade-cursor {
  display: inline-block;
  width: 1ch;
  height: 1em;
  background: transparent;
  color: #ffd900;
  font-family: inherit;
  animation: blink 1.1s steps(1) infinite;
}

@keyframes blink {
  0%, 55% { opacity: 1; }
  56%, 100% { opacity: 0; }
}


/* Blinking block cursor */
.arcade-cursor {
  display: inline-block;
  width: 1ch;
  height: 1.15em;
  background: #ffd900;
  margin-left: -0.35em;
  border-radius: 1.5px;
  animation: blink-cursor 1.05s steps(1) infinite;
  vertical-align: bottom;
  pointer-events: none;
}

.arcade-terminal-prompt-wrap {
  margin: 2em auto 1em auto;
  max-width: 420px;
}

.arcade-terminal-label {
  font-family: 'Press Start 2P', monospace, sans-serif;
  color: #7ea452;
  font-size: 0.87em;
  margin-bottom: 0.5em;
  margin-left: 0.3em;
  opacity: 0.78;
  letter-spacing: 1px;
  text-shadow: 0 0 1px #c9df54a0;
  user-select: none;
}

@keyframes blink-cursor {
  0%, 60% { opacity: 1; }
  61%, 100% { opacity: 0; }
}

/* ARCADE BUTTON */

.arcade-btn {
  font-family: 'Press Start 2P', 'VT323', 'Courier New', monospace;
  font-size: 1.15em;
  background: #232d1d;                  /* Menu dark background */
  color: #fffde5;
  border-style: solid;
  border-width: 3px;
  border-top-color: #f0e993;            /* Light "highlight" */
  border-left-color: #c9df54;           /* Lime left edge */
  border-bottom-color: #191f12;         /* Dark bottom "shadow" */
  border-right-color: #183c14;          /* Dark green right shadow */
  border-radius: 0;
  padding: 0.7em 2em 0.65em 2em;
  letter-spacing: 1.5px;
  text-shadow:
    0 0 2px #c9df5488,
    0 1px 0 #000a;
  box-shadow: none;
  cursor: pointer;
  margin: auto;
  margin-top: 0.5em;
  display: inline-block;
  outline: none;
  transition:
    background 0.12s,
    color 0.12s,
    border-color 0.12s;
}

.arcade-btn:hover,
.arcade-btn:focus {
  background: #344925;
  border-top-color: #fffbe8;
  border-left-color: #ffd900;           /* Brighter lime highlight */
  border-bottom-color: #232d1d;
  border-right-color: #242414;
  color: #fffde5;
}

.arcade-btn:active {
  background: #191f12;
  border-top-color: #232d1d;            /* "Pressed in" shadow */
  border-left-color: #183c14;
  border-bottom-color: #fffde5;         /* Light now on bottom */
  border-right-color: #c9df54;          /* Lime now on right */
  color: #c9df54;
}

/* ---------- Main content area ---------- */
main {
  flex: 1 0 auto;
  padding: 0em 3em;
}
.main-container {
  display: flex;
  flex-direction: column;
  max-width: 1020px;
  margin: 1.2rem auto 0 auto;
  position: relative;
  width: 100%;
  max-width: 100vw;
  min-height: 450px;
  margin: 0.7rem auto 0 auto;
  border-radius: 0;
  overflow-x: hidden;
  position: relative;
  z-index: 1;
  background:
    linear-gradient(135deg, #fff3 1px, transparent 1px),
    linear-gradient(-135deg, #fff3 1px, transparent 1px),
    #232931;
  box-sizing: border-box;
  font-size: 0.5em;
}

.main-container h1 {
  margin: 0.5em 0;
}

.quickstart-title {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25em;
  color: #ffd900;
  letter-spacing: 1px;
  font-weight: bold;
  margin-bottom: 1.3em;
  gap: 0.5em;
}
.qs-icon {
  width: 3em;
  height: 3em;
  vertical-align: -0.25em;
  display: inline-block;
  margin: 0;
}

.info-list {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1em;
}
.info-list li {
  display: flex;
  flex-direction: row;
  align-items: center;
  background: #30742a;
  border: 1.5px solid #183c14;
  border-radius: 10px;
  padding: 0.75em 0.85em;
  gap: 1.2em;
}

.qs-icon-col {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3em;
  min-width: 3em;
  height: 3em;
}
.qs-icon-col img {
  width: 2.2em;
  height: 2.2em;
  display: block;
  margin: auto;
  filter: drop-shadow(0 0 3px #0004);
}

.qs-text-col {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.15em;
}
.qs-step-title {
  font-weight: bold;
  color: #ffe956;
  font-size: 1.07em;
  letter-spacing: 0.5px;
  display: block;
  line-height: 1.25;
}
.qs-step-note {
  display: block;
  color: #b4ed74;
  font-size: 0.96em;
  margin-top: 0.10em;
  font-weight: normal;
  line-height: 1.22;
}

@media (max-width: 600px) {
  .quickstart-block {
    padding: 1em 0.6em;
    font-size: 1em;
  }
  .quickstart-title {
    font-size: 1em;
  }
  .quickstart-steps li {
    gap: 0.8em;
    padding: 0.5em 0.3em;
  }
  .qs-icon-col {
    width: 2.2em;
    min-width: 2.2em;
    height: 2.2em;
  }
  .qs-icon-col img {
    width: 1.6em; height: 1.6em;
  }
}

/* WIN MODAL */

.arcade-modal {
  position: fixed;
  inset: 0;
  z-index: 9999 !important; /* Ensures always top */
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}
.arcade-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(24, 60, 20, 0.85);
  backdrop-filter: blur(3px);
  z-index: 1;
  pointer-events: auto;
}

.arcade-modal-content {
  position: relative;
  z-index: 2;
  pointer-events: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1em;
  background: rgba(20,40,20,0.0); /* Transparent for your vibe */
  padding: 3em 2.5em 2em 2.5em;
  border-radius: 1.5em;
  min-width: 340px;
}

.arcade-modal-title {
  font-family: 'VT323', monospace;
  font-size: 3rem;
  font-weight: bold;
  color: #ffe800;
  letter-spacing: 2px;
  margin-bottom: 0.5em;
  text-shadow: 0 0 12px #ffd700, 0 2px 8px #202800;
  text-align: center;
  animation: win-pop 0.7s cubic-bezier(.17, .67, .83, .67);
}
@keyframes win-pop {
  0%   { transform: scale(0.7) rotate(-8deg); opacity: 0.2;}
  55%  { transform: scale(1.1) rotate(4deg); opacity: 1;}
  90%  { transform: scale(0.97) rotate(-2deg);}
  100% { transform: scale(1) rotate(0);}
}

.arcade-modal-score, .arcade-modal-message {
  font-family: 'VT323', monospace;
  font-size: 1.5rem;
  color: #fffed0;
  text-align: center;
  margin-bottom: 0.5em;
}

.arcade-modal-btn {
  margin-top: 1em;
  padding: 0.8em 2em;
  font-size: 1.2em;
  border-radius: 1em;
  background: #ffe800;
  color: #224611;
  border: none;
  font-family: inherit;
  cursor: pointer;
  box-shadow: 0 2px 12px #111a;
  font-weight: bold;
  transition: background 0.2s, color 0.2s;
}
.arcade-modal-btn:hover { background: #ffb800; color: #183c14; }

/* --- Confetti --- */
.confetti-piece {
  position: absolute;
  width: 12px;
  height: 18px;
  border-radius: 2px;
  opacity: 0.92;
  z-index: 10000;
  pointer-events: none;
  animation: confetti-fall linear forwards;
}

@keyframes confetti-fall {
  to {
    transform: translateY(120vh) rotate(320deg);
    opacity: 0.2;
  }
}

#game-lose-modal {
  background-color: blue;
}

/* ---------- Footer ---------- */
.arcade-footer {
  text-align: center;
  padding: 0.8rem 0.2rem 1.1rem 0.2rem;
  font-size: 0.85rem;
  letter-spacing: 2px;
  background: linear-gradient(180deg, #4C933F 0%, #417c36 90%, #183c14 100%);
  color: #fff;
  border-top: 0;
  border-bottom: 0;
  width: 100%;
  font-family: 'Press Start 2P', sans-serif;
  text-shadow:
    0 2px 2px #183c14cc,
    0 1px 0 #fff6;
  flex-shrink: 0;
}
.arcade-footer nav {
  margin-top: 0.5em;
  font-size: 0.86em;
}
.arcade-footer a,
.arcade-footer button {
  color: #fff !important;
  text-decoration: underline;
  text-underline-offset: 2px;
  margin: 0 0.6em;
  font-family: inherit;
  background: none;
  border: none;
  transition: opacity 0.18s;
  cursor: pointer;
  text-shadow:
    0 1px 0 #fff6,
    0 2px 2px #183c14b3;
  font-size: inherit;
  letter-spacing: inherit;
  padding: 0;
}
.arcade-footer a:hover,
.arcade-footer a:focus,
.arcade-footer button:hover,
.arcade-footer button:focus {
  opacity: 0.75;
}

/* ---------- SCANLINE OVERLAY FOR CRT EFFECT ---------- */
.scanline-overlay {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  opacity: 0.7;
  background:
    url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="4" height="4" viewBox="0 0 4 4"><rect width="4" height="1" fill="white" fill-opacity="0.08"/></svg>');
  mix-blend-mode: overlay;
  background-repeat: repeat;
  background-size: auto;
}


/* ---------- DESKTOP/TABLET STYLES (min-width: 786px) ---------- */
@media (min-width: 786px) {
  .arcade-header h1 {
    font-size: 2rem;
    margin: 0;
    text-align: center;
  }
  .arcade-header h1 a {
    text-align: center;
  }
  .arcade-header-top {
    flex-direction: row;
  }
  .arcade-header-row {
    height: 100px;
  }
  .arcade-header-bottom {
    font-size: 0.9em;
  }
  .arcade-header-bottom .header-copy {
    display: inline;
  }
  .arcade-dropdown {
    top: 50px;
    font-size: 1.5em;
  }
  .arcade-hud {
    min-height: 50px;
  }
  .hud-item {
    padding: 1em 0;
    font-size: 0.8em;
  }
  .pixel-logo-mobile {
    display: none;
  }
  .pixel-logo-desktop {
    display: inline-flex;
    margin: 0 0.5rem;
    vertical-align: middle;
  }
  .pixel-logo-desktop img {
    width: 64px;
    height: 64px;
  }
  .arcade-menu {
    font-size: 1.2em;
  }
  #wallet-address {
    font-size: 2em;
    padding: 0.5em;
  }
  main {
    padding: 0em 4rem;
    min-height:450px;
  }
  .main-container {
    margin: 1.2rem auto 0 auto;
    border-radius: 0;
    max-width: 820px;
    font-size: 1em;
  }
  .main-container .wallet-btn {
    font-size: 1em;
  }
  .games-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 240px));
    justify-content: center;
  }
  .game-content {
    padding: 1.1rem 1rem 1rem 1rem;
  }
  .game-title,
  .game-desc {
    font-size: 1.1rem;
  }
  .game-play-btn1 {
    font-size: 1.25rem;
    padding: 0.6rem 0;
  }
  .arcade-footer {
    font-size: 1.08rem;
    padding: 1.6rem 0 2.1rem 0;
  }
  .copy-to-cb {
    font-size: 1.2em;
    padding: 0.6em;
    justify-content: left;
  }
  .copy-to-cb::after {
    font-size: 1.2em;
    right: 0;
    padding: 0.6em;
  }
}


/* DEVELOPER MODE */
#dapplog {
  display: none;
}