* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  background: #000;
  color: #fff;
  font-family: "Segoe UI", Arial, sans-serif;
  overflow: hidden;
  cursor: none; /* kiosk display, no pointer needed */
}

.container {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
}

.background {
  position: fixed;
  top: 0;
  height: 100%;
  background-color: #000;
  background-image: 
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 48px 48px, 48px 48px;
  pointer-events: none;
  z-index: 0;
}

.background-left {
  left: 0;
  width: 50%;
  background-position: right 0, right 0, left center;
}

.background-right {
  right: 0;
  width: 50%;
  background-position: left 0, left 0, right center;
}

.center-column {
  position: fixed;
  left: 50%;
  top: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  transform: translateX(-50%);
  pointer-events: none;
  z-index: 3;
}

.center-line {
  flex: 1 1 auto;
  min-height: 0;
  width: 2px;
  margin: 0.75em 0;
  border-left: 2px dashed rgba(255, 255, 255, 0.25);
}

canvas#pong {
  position: fixed;
  inset: 0;
  display: block;
  width: 100vw;
  height: 100vh;
  z-index: 2;
  background: transparent;
}

.score {
  position: fixed;
  top: 10%;
  font-size: clamp(1.5rem, 8vw, 6rem);
  font-weight: 700;
  color: rgba(255, 255, 255, 0.08);
  pointer-events: none;
  z-index: 1;
}

.left-score {
  left: 5%;
}

.right-score {
  right: 5%;
}

.score-value {
  font-family: "Courier New", monospace;
  letter-spacing: 0.1em;
}

.player-name {
  position: fixed;
  font-size: clamp(0.8rem, 3vw, 1.5rem);
  font-weight: 600;
  letter-spacing: 0.3em;
  color: rgba(255, 255, 255, 0.4);
  pointer-events: none;
  z-index: 1;
}

.left-name {
  left: 5%;
  top: 25%;
}

.right-name {
  right: 5%;
  top: 25%;
}

.brand {
  flex: 0 0 auto;
  padding-top: 2%;
  font-size: 0.75rem;
  letter-spacing: 0.4em;
  color: rgba(255, 255, 255, 0.45);
  font-weight: 600;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.4);
  white-space: nowrap;
}

.footer {
  flex: 0 0 auto;
  padding-bottom: 3%;
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  color: rgba(255, 255, 255, 0.25);
  text-transform: uppercase;
  white-space: nowrap;
}

/* Focus ring for keyboard play, inset so the overscan edge stays visible */
canvas#pong:focus {
  outline: 2px solid rgba(255, 255, 255, 0.35);
  outline-offset: -2px;
}

/* Pointer drags move the paddle instead of scrolling */
canvas#pong {
  touch-action: none;
}

.hint {
  flex: 0 0 auto;
  margin-bottom: 0.75em;
  font-family: "Courier New", monospace;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  color: rgba(255, 255, 255, 0.45);
  white-space: nowrap;
}

/* Embed mode: only field, scores and names */
.embed .brand,
.embed .footer {
  display: none;
}

.embed .center-line {
  margin-top: 0;
}

.embed,
.embed body {
  cursor: default;
}
