/* Illustrated enamel faces fitted to the original console’s inner wells.
 * Console asset: 1536 × 961; drawn at (0, 1152, 1000, 625.472888).
 * Exact source bounds and masks: assets/chicken/mobile/portrait-control-faces.json.
 * Hit areas remain at least 44 CSS pixels; face sizes track the cabinet artwork.
 */
#portraitTurboButton { display: none; }

html[data-slot-orientation="portrait"] #gameShell .controls .artHit {
  min-width: 44px;
  min-height: 44px;
  margin: 0;
  padding: 0;
  appearance: none;
  border: 0;
  outline: 0;
  background: transparent;
  box-shadow: none;
  opacity: 1;
  transform: translate(-50%, -50%);
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
html[data-slot-orientation="portrait"] #gameShell .controls .artHit::before {
  content: '';
  position: absolute;
  display: block;
  left: 50%;
  top: 50%;
  width: var(--portrait-face-width);
  height: var(--portrait-face-height, var(--portrait-face-width));
  border-radius: 0;
  opacity: 1;
  background-position: center;
  background-repeat: no-repeat;
  background-size: 100% 100%;
  transform: translate(-50%, -50%);
  filter: drop-shadow(0 2px 2px #080b07a6);
  transition: filter 100ms ease;
  pointer-events: none;
}
html[data-slot-orientation="portrait"] #gameShell .controls .artHit:hover:not(:disabled)::before {
  filter: brightness(1.08) drop-shadow(0 2px 2px #080b07a6);
}
html[data-slot-orientation="portrait"] #gameShell .controls .artHit:active:not(:disabled)::before {
  filter: brightness(.96) drop-shadow(0 1px 1px #080b07a6);
}
html[data-slot-orientation="portrait"] #gameShell .controls .artHit:focus-visible {
  outline: 2px solid #fff2b8;
  outline-offset: -2px;
  box-shadow: 0 0 12px #ffd57466;
}
html[data-slot-orientation="portrait"] #gameShell .controls .artHit:disabled::before {
  display: block;
  opacity: .58;
  filter: saturate(.48) brightness(.86);
}

html[data-slot-orientation="portrait"] #gameShell #betDownButton,
html[data-slot-orientation="portrait"] #gameShell #betUpButton {
  top: 71.9997%;
  width: 11%;
  height: 6.1875%;
  border-radius: 50%;
  --portrait-face-width: calc(var(--slot-cabinet-width, 100vw) * .1015625);
}
html[data-slot-orientation="portrait"] #gameShell #betDownButton {
  left: 31.15234375%;
  top: 72.08552252%;
  --portrait-face-height: calc(var(--slot-cabinet-width, 100vw) * .1047878615);
}
html[data-slot-orientation="portrait"] #gameShell #betUpButton { left: 68.65234375%; top: 72.10382785%; --portrait-face-height: calc(var(--slot-cabinet-width, 100vw) * .1041370052); }
html[data-slot-orientation="portrait"] #gameShell #betDownButton::before { background-image: url('../assets/chicken/mobile/portrait-face-minus.webp'); }
html[data-slot-orientation="portrait"] #gameShell #betDownButton:active:not(:disabled)::before { background-image: url('../assets/chicken/mobile/portrait-face-minus.webp'); }
html[data-slot-orientation="portrait"] #gameShell #betUpButton::before { background-image: url('../assets/chicken/mobile/portrait-face-plus.webp'); }
html[data-slot-orientation="portrait"] #gameShell #betUpButton:active:not(:disabled)::before { background-image: url('../assets/chicken/mobile/portrait-face-plus.webp'); }

html[data-slot-orientation="portrait"] #gameShell #maxBetButton {
  left: 85.57942708%;
  top: 71.95738518%;
  width: 18%;
  height: 7.3%;
  border-radius: 16%;
  --portrait-face-width: calc(var(--slot-cabinet-width, 100vw) * .1705729167);
  --portrait-face-height: calc(var(--slot-cabinet-width, 100vw) * .1041370052);
}
html[data-slot-orientation="portrait"] #gameShell #maxBetButton::before { background-image: url('../assets/chicken/mobile/portrait-face-max.webp'); }
html[data-slot-orientation="portrait"] #gameShell #maxBetButton:active:not(:disabled)::before { background-image: url('../assets/chicken/mobile/portrait-face-max.webp'); }

html[data-slot-orientation="portrait"] #gameShell #menuButton,
html[data-slot-orientation="portrait"] #gameShell #autoButton {
  top: 86.41859822%;
  width: 20%;
  height: 11.25%;
  border-radius: 50%;
  --portrait-face-width: calc(var(--slot-cabinet-width, 100vw) * .1705729167);
  --portrait-face-height: calc(var(--slot-cabinet-width, 100vw) * .1718260587);
}
html[data-slot-orientation="portrait"] #gameShell #menuButton { left: 20.14973958%; }
html[data-slot-orientation="portrait"] #gameShell #autoButton { left: 79.4921875%; --portrait-face-width: calc(var(--slot-cabinet-width, 100vw) * .1712239583); }
html[data-slot-orientation="portrait"] #gameShell #menuButton::before { background-image: url('../assets/chicken/mobile/portrait-face-menu.webp'); }
html[data-slot-orientation="portrait"] #gameShell #menuButton:active:not(:disabled)::before { background-image: url('../assets/chicken/mobile/portrait-face-menu.webp'); }
html[data-slot-orientation="portrait"] #gameShell #autoButton::before { background-image: url('../assets/chicken/mobile/portrait-face-auto.webp'); }
html[data-slot-orientation="portrait"] #gameShell #autoButton.active::before { background-image: url('../assets/chicken/mobile/portrait-face-auto.webp'); }
html[data-slot-orientation="portrait"] #gameShell #autoButton:active:not(:disabled)::before { background-image: url('../assets/chicken/mobile/portrait-face-auto.webp'); }

html[data-slot-orientation="portrait"] #gameShell #spinButton {
  left: 49.8739%;
  top: 85.2642%;
  width: 29.5%;
  height: 16.59375%;
  border-radius: 50%;
  --portrait-face-width: calc(var(--slot-cabinet-width, 100vw) * .265);
}
html[data-slot-orientation="portrait"] #gameShell #spinButton::before { background-image: url('../assets/chicken/ui/controls/spin-over.png?v=6'); }
html[data-slot-orientation="portrait"] #gameShell #spinButton:active:not(:disabled)::before { background-image: url('../assets/chicken/ui/controls/spin-press.png?v=6'); }
html[data-slot-orientation="portrait"] #gameShell #spinButton.spinning {
  --portrait-face-width: calc(var(--slot-cabinet-width, 100vw) * .246);
  --portrait-face-height: calc(var(--slot-cabinet-width, 100vw) * .2571186);
}
html[data-slot-orientation="portrait"] #gameShell #spinButton.spinning::before { background-image: url('../assets/chicken/ui/controls/stop-over.png?v=6'); }
html[data-slot-orientation="portrait"] #gameShell #spinButton.spinning:active:not(:disabled)::before { background-image: url('../assets/chicken/ui/controls/stop-press.png?v=6'); }
html[data-slot-orientation="portrait"] #gameShell #spinButton.autoplayRunning::after {
  content: attr(data-autoplay-count);
  position: absolute;
  z-index: 3;
  left: calc(50% - var(--slot-cabinet-width, 100vw) * .00022);
  top: calc(50% - var(--slot-cabinet-width, 100vw) * .00786);
  width: calc(var(--slot-cabinet-width, 100vw) * .094);
  margin: 0;
  padding: 0;
  color: #18231e;
  font-family: Arial, Helvetica, sans-serif;
  font-size: clamp(14px, calc(var(--slot-cabinet-width, 100vw) * .065), 39px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -.035em;
  text-align: center;
  text-shadow: none;
  transform: translate(-50%, -50%);
  pointer-events: none;
}
html[data-slot-orientation="portrait"] #gameShell #spinButton.autoplayLargeCount::after {
  font-size: clamp(13px, calc(var(--slot-cabinet-width, 100vw) * .051), 31px);
}

/* The two illustrated turbo states share the original Max Bet face's brass
 * frame and amber palette. Both atlas cells have identical geometry. */
html[data-slot-orientation="portrait"] #gameShell #portraitTurboButton {
  display: block;
  left: 14.35546875%;
  top: 71.95738518%;
  width: 18%;
  height: 7.3%;
  border-radius: 16%;
  font-size: 0;
  --portrait-face-width: calc(var(--slot-cabinet-width, 100vw) * .1705729167);
  --portrait-face-height: calc(var(--slot-cabinet-width, 100vw) * .1041370052);
}
html[data-slot-orientation="portrait"] #gameShell #portraitTurboButton::before {
  left: 50%;
  background-image: url('../assets/chicken/mobile/portrait-face-turbo-states.webp');
  background-size: 100% 200%;
  background-position: center top;
  filter: drop-shadow(0 2px 2px #080b07a6);
}
html[data-slot-orientation="portrait"] #gameShell #portraitTurboButton[aria-pressed="true"]::before {
  background-position: center bottom;
}
html[data-slot-orientation="portrait"] #gameShell #portraitTurboButton:hover:not(:disabled)::before {
  filter: brightness(1.08) drop-shadow(0 2px 2px #080b07a6);
}
html[data-slot-orientation="portrait"] #gameShell #portraitTurboButton:active:not(:disabled)::before {
  filter: brightness(.86) drop-shadow(0 1px 1px #080b07a6);
}
html[data-slot-orientation="portrait"] #gameShell #portraitTurboButton:disabled::before {
  opacity: .58;
  filter: saturate(.48) brightness(.86);
}
html[data-slot-orientation="portrait"] #gameShell #portraitTurboButton::after,
html[data-slot-orientation="portrait"] #gameShell #portraitTurboButton[aria-pressed="true"]::after { content: none; }
html[data-slot-orientation="portrait"] #gameShell #portraitTurboButton > * { display: none; }

html[data-slot-orientation="portrait"] #gameShell .betMeter {
  left: 49.9369%;
  top: 71.9997%;
  width: 20.4%;
  height: 6.1%;
  display: grid;
  grid-template-rows: auto auto;
  place-items: center;
  align-content: center;
  gap: 3px;
  transform: translate(-50%, -50%);
}
html[data-slot-orientation="portrait"] #gameShell .betMeter > span {
  position: static;
  display: block;
  width: auto;
  height: auto;
  overflow: visible;
  clip: auto;
  color: #d9b971;
  font-size: clamp(8px, calc(var(--slot-cabinet-width, 100vw) * .022), 13px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: .06em;
  text-transform: uppercase;
  text-shadow: 0 1px 2px #000;
}
html[data-slot-orientation="portrait"] #gameShell .betMeter strong {
  position: static;
  width: max-content;
  color: #fff0a5;
  font-family: Impact, Haettenschweiler, 'Arial Narrow Bold', sans-serif;
  font-size: clamp(13px, calc(var(--slot-cabinet-width, 100vw) * .043), 25px);
  line-height: 1;
  letter-spacing: .015em;
  text-shadow: 0 2px 2px #000;
}

/* The console supplies the brass holders and shadows. These cutout enamel
 * faces fill the wells directly, with no second frame or black backing plate. */
html[data-slot-orientation="portrait"] #gameShell .controls .artHit:not(#spinButton)::before { filter: none; }
html[data-slot-orientation="portrait"] #gameShell .controls .artHit:not(#spinButton):hover:not(:disabled)::before { filter: brightness(1.06); }
html[data-slot-orientation="portrait"] #gameShell .controls .artHit:not(#spinButton):active:not(:disabled)::before { filter: brightness(.82) saturate(1.06); }
html[data-slot-orientation="portrait"] #gameShell .controls .artHit:not(#spinButton):disabled::before { opacity: .58; filter: saturate(.48) brightness(.86); }

/* Keep the atlas on one compositor layer. Neighboring control state changes
 * otherwise switch its fractional-size raster sampling for a frame on Spin,
 * making the artwork appear to shrink or disappear despite unchanged geometry. */
html[data-slot-orientation="portrait"] #gameShell #portraitTurboButton::before {
  will-change: transform;
  transform: translate3d(-50%, -50%, 0);
}

/* Turbo has explicit electrical toggle feedback. Keep its painted face steady
 * when mouse or touch hover leaves for Spin, avoiding a second brightness flash. */
html[data-slot-orientation="portrait"] #gameShell .controls #portraitTurboButton.artHit:not(:disabled)::before,
html[data-slot-orientation="portrait"] #gameShell .controls #portraitTurboButton.artHit:hover:not(:disabled)::before,
html[data-slot-orientation="portrait"] #gameShell .controls #portraitTurboButton.artHit:active:not(:disabled)::before {
  filter: none;
  transition: none;
}
