:root {
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #10231c;
  color: #f4fff8;
  touch-action: none;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
}

button,
select {
  font: inherit;
}

.shell {
  position: fixed;
  inset: 0;
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-width: 320px;
  min-height: 100%;
  background: #10231c;
}

#game {
  width: 100%;
  height: 100%;
  min-height: 0;
  display: block;
  touch-action: none;
}

.hud {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: max(10px, env(safe-area-inset-top)) 12px 10px;
  background: rgba(11, 26, 20, 0.82);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.hud-top > div {
  min-width: 58px;
}

.hud-bottom {
  flex-direction: column;
  align-items: stretch;
  padding: 10px 12px max(12px, env(safe-area-inset-bottom));
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  border-bottom: 0;
}

.label,
label {
  display: block;
  color: rgba(244, 255, 248, 0.68);
  font-size: 11px;
  line-height: 1.1;
  text-transform: uppercase;
}

strong {
  display: block;
  font-size: 18px;
  line-height: 1.1;
}

button,
select {
  min-height: 38px;
  color: #f4fff8;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  padding: 0 12px;
}

#reset {
  width: 38px;
  margin-left: auto;
  padding: 0;
  font-size: 24px;
}

.player-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.player {
  min-height: 48px;
  padding: 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.player.is-active {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.45);
}

.player span {
  display: block;
  color: rgba(244, 255, 248, 0.65);
  font-size: 11px;
}

.player b {
  display: block;
  margin-top: 2px;
  font-size: 16px;
}

.controls {
  display: grid;
  grid-template-columns: minmax(76px, 1fr) auto auto;
  gap: 10px;
  align-items: end;
}

#club,
#swingMode {
  min-width: 76px;
}

select {
  width: 100%;
  margin-top: 4px;
}

@media (min-width: 720px) {
  .shell {
    max-width: 480px;
    margin: 0 auto;
    border-inline: 1px solid rgba(255, 255, 255, 0.12);
  }
}
