.video-poker-body .poker-game-panel {
  display: grid;
  gap: 1rem;
  overflow: hidden;
}

.bet-stepper {
  display: grid;
  grid-template-columns: 3.2rem minmax(0, 1fr) 3.2rem;
  gap: 0.45rem;
}

.bet-stepper input {
  min-width: 0;
}

.step-button {
  min-height: 2.7rem;
  border: 1px solid #335368;
  border-radius: 0.45rem;
  background: #102b38;
  color: #dcecf4;
  font-weight: 950;
  cursor: pointer;
}

.step-button:hover,
.step-button:focus-visible {
  border-color: #73cfff;
  background: #173849;
}

.poker-stage-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(13rem, 17rem);
  gap: 1rem;
  align-items: stretch;
}

.poker-machine {
  position: relative;
  display: grid;
  gap: 1rem;
  min-height: 35rem;
  padding: 1rem;
  overflow: hidden;
  border-radius: 0.45rem;
  background:
    radial-gradient(circle at 50% 24%, rgba(21, 214, 132, 0.13), transparent 12rem),
    radial-gradient(circle at 78% 86%, rgba(79, 156, 255, 0.10), transparent 15rem),
    linear-gradient(180deg, #071b26, #081722);
}

.poker-machine::before {
  content: "";
  position: absolute;
  inset: 0.75rem;
  border-radius: 0.45rem;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.023) 1px, transparent 1px),
    linear-gradient(0deg, rgba(255, 255, 255, 0.023) 1px, transparent 1px);
  background-size: 4rem 4rem;
  pointer-events: none;
}

.poker-machine-top,
.poker-result-strip,
.hold-strip {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 3.25rem;
  padding: 0.75rem 0.85rem;
  border-radius: 0.45rem;
  background: #102d3a;
  color: #c5dce7;
}

.poker-machine-top > div {
  min-width: 0;
}

.poker-machine-top strong,
.poker-result-strip strong {
  display: block;
  color: #f8fcff;
  overflow-wrap: anywhere;
}

.poker-result-strip strong {
  color: #1fed73;
  font-size: clamp(1.25rem, 3.4vw, 2rem);
}

.hand-block {
  position: relative;
  z-index: 2;
  display: grid;
  gap: 0.7rem;
}

.hand-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  color: #eff8fc;
  font-weight: 950;
}

.hand-title small {
  max-width: 28rem;
  color: #95b4c4;
  font-size: 0.76rem;
  font-weight: 750;
  text-align: right;
}

.card-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(4.4rem, 1fr));
  gap: 0.75rem;
  width: min(100%, 42rem);
  margin: 0 auto;
}

.poker-card {
  position: relative;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  min-height: 7.1rem;
  padding: 0.55rem;
  border: 2px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.42rem;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(221, 232, 237, 0.96));
  color: #10202b;
  font-weight: 950;
  box-shadow:
    inset 0 -0.25rem 0 rgba(0, 0, 0, 0.08),
    0 0.5rem 0.85rem rgba(0, 0, 0, 0.18);
  cursor: pointer;
  transition: transform 0.14s ease, border-color 0.14s ease, box-shadow 0.14s ease, filter 0.14s ease;
}

.poker-card.placeholder {
  place-items: center;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.06), transparent 40%),
    linear-gradient(180deg, #233d4c, #162c38);
  color: #8fafbd;
  cursor: default;
}

.poker-card:not(.placeholder):hover,
.poker-card:not(.placeholder):focus-visible {
  transform: translateY(-0.08rem);
  border-color: #83d8ff;
  outline: none;
}

.poker-card.held {
  border-color: #1ef568;
  box-shadow:
    0 0 0 0.18rem rgba(30, 245, 104, 0.24),
    0 0.65rem 1rem rgba(0, 0, 0, 0.24);
}

.poker-card.discarded {
  filter: grayscale(0.4) brightness(0.8);
  opacity: 0.65;
}

.poker-card.drawn {
  animation: poker-card-pop 0.24s ease both;
}

.poker-card.red {
  color: #d92354;
}

.poker-card.black {
  color: #112432;
}

.card-corner {
  display: grid;
  gap: 0.1rem;
  line-height: 0.9;
}

.card-corner.bottom {
  justify-self: end;
  align-self: end;
  transform: rotate(180deg);
}

.card-rank {
  font-size: clamp(1rem, 2.2vw, 1.35rem);
}

.card-suit {
  font-size: clamp(1.05rem, 2.4vw, 1.45rem);
}

.card-centre {
  align-self: center;
  justify-self: center;
  font-size: clamp(1.8rem, 5vw, 3.4rem);
  line-height: 1;
}

.hold-badge {
  position: absolute;
  left: 50%;
  bottom: -0.78rem;
  transform: translateX(-50%);
  display: none;
  min-width: 3.6rem;
  padding: 0.25rem 0.45rem;
  border-radius: 999px;
  background: #1fed73;
  color: #052014;
  font-size: 0.68rem;
  line-height: 1;
  text-align: center;
  box-shadow: 0 0.35rem 0.6rem rgba(0, 0, 0, 0.26);
}

.poker-card.held .hold-badge {
  display: block;
}

.hold-strip {
  justify-content: center;
  min-height: 2.65rem;
  background: rgba(16, 45, 58, 0.72);
  color: #b9d1dd;
  text-align: center;
}

.poker-paytable-card {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  gap: 0.7rem;
  padding: 1rem;
  border: 1px solid #2f556b;
  border-radius: 0.45rem;
  background: #143543;
  color: #eaf6fb;
}

.poker-paytable-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
}

.poker-paytable-header span {
  color: #a8dfff;
  font-size: 0.78rem;
  font-weight: 950;
}

.poker-paytable-columns,
.poker-paytable-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 4.5rem;
  gap: 0.75rem;
  align-items: center;
}

.poker-paytable-columns {
  color: #9fbdca;
  font-size: 0.74rem;
  font-weight: 950;
}

.poker-paytable-list {
  display: grid;
  align-content: start;
  gap: 0.4rem;
  overflow: auto;
  padding-right: 0.2rem;
}

.poker-paytable-row {
  min-height: 2.4rem;
  padding: 0.45rem 0.55rem;
  border-radius: 0.35rem;
  background: #0d2a36;
  font-weight: 900;
}

.poker-paytable-row.current {
  background: #0f5c3e;
  color: #ffffff;
  box-shadow: 0 0 0 0.12rem rgba(31, 237, 115, 0.34);
}

.poker-paytable-row span:last-child {
  color: #ffffff;
  text-align: right;
}

.poker-recent-results .recent-chip.win {
  background: #15d679;
  color: #042416;
}

.poker-recent-results .recent-chip.loss {
  background: #314a5a;
  color: #e2eef3;
}

.poker-result-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.mode-panel {
  display: grid;
  gap: 0.7rem;
}

.auto-pacing {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.7rem;
  align-items: end;
}

.turbo-row {
  min-height: 2.75rem;
}

@keyframes poker-card-pop {
  from {
    opacity: 0;
    transform: translateY(-0.65rem) rotate(-2deg);
  }
  to {
    opacity: 1;
    transform: translateY(0) rotate(0);
  }
}

@media (max-width: 1060px) {
  .poker-stage-grid {
    grid-template-columns: 1fr;
  }

  .poker-paytable-card {
    min-height: 0;
  }
}

@media (max-width: 760px) {
  .video-poker-body .crash-layout,
  .video-poker-body .crash-layout.stats-open {
    grid-template-columns: 1fr;
    padding: 0;
  }

  .video-poker-body .live-stats-drawer {
    border-radius: 0;
  }

  .crash-controls {
    border-radius: 0;
  }

  .card-row {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.38rem;
  }

  .poker-card {
    min-height: 5.5rem;
    padding: 0.42rem;
  }

  .card-rank {
    font-size: 0.95rem;
  }

  .card-suit {
    font-size: 1rem;
  }

  .card-centre {
    font-size: 1.65rem;
  }

  .hand-title {
    display: grid;
    gap: 0.25rem;
  }

  .hand-title small {
    max-width: none;
    text-align: left;
  }

  .poker-machine {
    min-height: 0;
    padding: 0.75rem;
    border-radius: 0;
  }

  .poker-machine-top,
  .poker-result-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .poker-result-grid {
    grid-template-columns: 1fr 1fr;
  }

  .auto-pacing {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 420px) {
  .poker-card {
    min-height: 4.7rem;
  }

  .card-centre {
    display: none;
  }

  .hold-badge {
    min-width: 2.7rem;
    font-size: 0.58rem;
  }
}
