@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600&family=Plus+Jakarta+Sans:wght@600;700&display=swap');
:root {
  --bg: #0C1016;
  --surface: #161C26;
  --surface-2: #1E2633;
  --border: #2C3646;
  --text: #F2F5F8;
  --muted: #8E9AAB;
  --accent: #C4A574;
  --accent-hover: #E0C08A;
  --accent-ink: #1A140C;
  --danger: #E05D5D;
  --success: #3DDC97;
  --walnut: #3A2F28;
  --cream: #E7D7C1;
  --checker-dark: #1A1D24;
  --checker-cream: #F4EDE3;
  --glow: rgba(196, 165, 116, 0.65);
  --glow-mid: rgba(196, 165, 116, 0.45);
  --glow-soft: rgba(196, 165, 116, 0.35);
  --radius-panel: 12px;
  --radius-control: 8px;
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  --motion: 150ms ease;
  --focus: rgba(196, 165, 116, 0.4);
}
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.45;
  font-variant-numeric: tabular-nums;
}
button,
input,
a {
  font-family: inherit;
}
button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
h1,
.title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 28px;
  line-height: 1.2;
  letter-spacing: 0;
  color: var(--text);
  text-align: center;
  margin: 28px 0 20px;
}
h2 {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 600;
  font-size: 16px;
  line-height: 1.3;
  color: var(--text);
  margin: 0;
}
.field-label {
  font-family: Inter, sans-serif;
  font-weight: 600;
  font-size: 12px;
  line-height: 1.2;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
#app {
  min-height: 100vh;
  background: var(--bg);
  padding: 0 16px 40px;
}
.landing-container .landing-page {
  width: 100%;
  text-align: center;
}
.landing-container .landing-page a {
  display: block;
  text-decoration: none;
}
.action-card {
  width: 280px;
  max-width: 100%;
  margin: 0 auto;
  padding: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-control);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  text-align: left;
}
.action-card h2 {
  text-align: left;
  margin-bottom: 4px;
}
.action-card a + a {
  margin-top: 2px;
}
button,
.intro {
  display: inline-block;
  width: auto;
  margin: 0;
  padding: 10px 14px;
  border-radius: var(--radius-control);
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  font-family: Inter, sans-serif;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  transition: background-color var(--motion), border-color var(--motion), color var(--motion), transform var(--motion);
}
button:hover,
.intro:hover {
  border-color: var(--accent);
}
button.primary,
.intro.primary,
.buttons .end.green {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
button.primary:hover,
.intro.primary:hover,
.buttons .end.green:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: var(--accent-ink);
}
button.danger {
  background: transparent;
  border-color: var(--danger);
  color: var(--danger);
}
button.danger:hover {
  background: transparent;
  border-color: var(--danger);
  color: var(--danger);
}
button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.action-card .intro,
.action-card button {
  width: 100%;
}
input {
  display: block;
  width: 100%;
  margin: 0;
  padding: 10px 12px;
  border-radius: var(--radius-control);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  font-weight: 400;
  text-align: left;
  font-variant-numeric: tabular-nums;
  box-shadow: none;
}
input:required {
  box-shadow: none;
}
input::placeholder {
  color: var(--muted);
}
.game-container {
  max-width: 980px;
  margin: 0 auto;
}
.top-display {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  grid-template-areas: "banner banner banner" "status status status" "p1 mid p2";
  gap: 8px 16px;
  align-items: center;
  margin: 0 auto 16px;
  padding: 12px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-panel);
  box-shadow: var(--shadow);
}
.top-display .turn-row {
  grid-area: banner;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 12px;
}
.top-display .status {
  grid-area: status;
  margin: 0 auto;
  max-width: 70ch;
  text-align: center;
  font-family: Inter, sans-serif;
  font-size: 14px;
  font-weight: 400;
  font-style: normal;
  color: var(--text);
}
.top-display .hidden {
  display: none;
}
.top-display .player-one {
  grid-area: p1;
  justify-self: end;
  max-width: 100%;
  text-align: right;
}
.top-display .player-two {
  grid-area: p2;
  justify-self: start;
  max-width: 100%;
  text-align: left;
}
.top-display .mid {
  grid-area: mid;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 0;
  text-align: center;
}
.top-display .white,
.top-display .black {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 16px;
}
.top-display .player-one .white,
.top-display .player-one .black {
  justify-content: flex-end;
}
.top-display .player-two .white,
.top-display .player-two .black {
  justify-content: flex-start;
}
.top-display .player-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 220px;
}
.top-display .turn {
  font-style: normal;
}
.top-display .player-one,
.top-display .player-two {
  padding: 6px 10px;
  border: 2px solid transparent;
  border-radius: var(--radius-control);
  transition: opacity var(--motion), border-color var(--motion), background-color var(--motion);
}
.top-display .inactive-side {
  opacity: 0.4;
}
.top-display .active-side {
  border-color: var(--glow);
  background: var(--glow-soft);
  animation: dice-ready-glow 1.4s ease-in-out infinite;
}
.top-display.turn-white .active-side .player-name {
  color: var(--checker-cream);
}
.top-display.turn-black .active-side .player-name {
  color: #C9D3E3;
}
.top-display.turn-white,
.cube.turn-white {
  --glow: rgba(244, 237, 227, 0.8);
  --glow-mid: rgba(244, 237, 227, 0.5);
  --glow-soft: rgba(244, 237, 227, 0.14);
}
.top-display.turn-black,
.cube.turn-black {
  --glow: rgba(120, 140, 175, 0.9);
  --glow-mid: rgba(120, 140, 175, 0.55);
  --glow-soft: rgba(120, 140, 175, 0.16);
}
.turn-banner {
  padding: 8px 18px;
  border-radius: 999px;
  font-family: Inter, sans-serif;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.02em;
  animation: dice-ready-glow 1.4s ease-in-out infinite;
}
.turn-banner.banner-white {
  background: var(--checker-cream);
  color: var(--checker-dark);
  border: 2px solid var(--checker-cream);
}
.turn-banner.banner-black {
  background: var(--checker-dark);
  color: #E6EBF3;
  border: 2px solid rgba(120, 140, 175, 0.9);
}
.you-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-family: Inter, sans-serif;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--border);
  color: var(--text);
}
.you-badge.you-white {
  background: var(--checker-cream);
  color: var(--checker-dark);
  border-color: var(--checker-cream);
}
.you-badge.you-black {
  background: var(--checker-dark);
  color: #E6EBF3;
  border-color: rgba(120, 140, 175, 0.9);
}
.top-display .buttons {
  display: flex;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.top-display .buttons li {
  list-style: none;
  margin: 0;
}
.top-display .buttons button {
  min-width: 76px;
  padding: 8px 12px;
}
.top-display .buttons .end:not(.green) {
  opacity: 0.4;
}
.top-display .dice {
  display: flex;
  gap: 8px;
  justify-content: center;
  align-items: center;
  margin: 0;
  padding: 0;
  list-style: none;
  cursor: default;
}
.top-display .dice li {
  list-style: none;
  margin: 0;
}
.top-display .dice.ready {
  cursor: pointer;
}
.top-display .dice.disabled {
  cursor: not-allowed;
  opacity: 0.55;
}
.top-display .roll-hint {
  margin: 0;
  font-family: Inter, sans-serif;
  font-size: 12px;
  color: var(--text-muted, #9aa0aa);
}
.top-display .pad {
  margin: 0;
}
.die {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: #f4f1ea;
  border: 1px solid #c8c2b4;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7), 0 1px 2px rgba(0, 0, 0, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  font-variant-numeric: tabular-nums;
  color: #1a1a1a;
}
.die.used {
  opacity: 0.4;
}
.die.placeholder {
  opacity: 0.92;
}
.die-face {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
  width: 100%;
  height: 100%;
  padding: 6px;
}
.pip {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  align-self: center;
  justify-self: center;
  background: transparent;
}
.pip.on {
  background: #1a1a1a;
}
.die-num {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  font-family: Inter, sans-serif;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  font-size: 13px;
  line-height: 1;
  color: #1a1a1a;
}
.dice.ready {
  animation: dice-ready-glow 1.4s ease-in-out infinite;
}
.dice.ready .die {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7), 0 0 0 2px var(--glow-soft), 0 0 14px var(--glow-mid);
}
.buttons .end.green {
  animation: dice-ready-glow 1.4s ease-in-out infinite;
  box-shadow: 0 0 0 2px var(--glow-soft), 0 0 14px var(--glow-mid);
}
.confirm-overlay {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.55);
}
.confirm-card {
  width: 320px;
}
.confirm-card h2 {
  margin: 0 0 6px;
  font-size: 18px;
}
.confirm-actions {
  display: flex;
  gap: 8px;
}
.confirm-actions button {
  flex: 1;
}
.die.rolling {
  animation: die-tumble 0.65s ease-in-out;
}
.die.rolling .die-face {
  animation: die-face-spin 0.12s linear infinite;
}
@keyframes dice-ready-glow {
  0%,
  100% {
    filter: drop-shadow(0 0 0 transparent);
  }
  50% {
    filter: drop-shadow(0 0 8px var(--glow));
  }
}
@keyframes die-tumble {
  0% {
    transform: rotate(0deg) scale(1);
  }
  25% {
    transform: rotate(-18deg) scale(1.06);
  }
  50% {
    transform: rotate(16deg) scale(0.96);
  }
  75% {
    transform: rotate(-10deg) scale(1.04);
  }
  100% {
    transform: rotate(0deg) scale(1);
  }
}
@keyframes die-face-spin {
  0% {
    opacity: 0.55;
    transform: scale(0.92);
  }
  50% {
    opacity: 1;
    transform: scale(1.08);
  }
  100% {
    opacity: 0.55;
    transform: scale(0.92);
  }
}
.board {
  --pad: 16px;
  --half: 236px;
  --bar: 76px;
  --home: 112px;
  --home-gap: 8px;
  --piece: 32px;
  position: relative;
  box-sizing: border-box;
  width: 100%;
  max-width: 980px;
  margin: 0 auto;
  padding: var(--pad);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-panel);
  box-shadow: var(--shadow);
  /* Each checker advances most of its own height; long stacks compress to fit the point */
}
.board .board-top,
.board .board-bottom {
  display: flex;
  width: 100%;
  height: var(--half);
  margin: 0;
  padding: 0;
  list-style: none;
}
.board .board-top > li,
.board .board-bottom > li {
  list-style: none;
  position: relative;
  min-width: 0;
}
.board .board-top {
  align-items: stretch;
}
.board .board-bottom {
  align-items: stretch;
}
.board .space {
  flex: 1 1 0;
  height: 100%;
  background: none;
}
.board .bar {
  flex: 0 0 var(--bar);
  height: 100%;
  background: var(--bg);
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
}
.board .home {
  flex: 0 0 var(--home);
  height: 100%;
  margin-left: var(--home-gap);
  background: var(--bg);
  border: 1px solid var(--border);
}
.board .board-top .bar {
  border-radius: var(--radius-control) var(--radius-control) 0 0;
}
.board .board-bottom .bar {
  border-radius: 0 0 var(--radius-control) var(--radius-control);
}
.board .cube {
  position: absolute;
  z-index: 5;
  top: calc(var(--pad) + var(--half));
  left: calc(50% - (var(--home) + var(--home-gap)) / 2);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-control);
  box-shadow: var(--shadow);
  color: var(--checker-cream);
  font-family: Inter, sans-serif;
  font-weight: 600;
  font-size: 16px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  pointer-events: none;
  transform: translate(-50%, -50%);
  transition: border-color var(--motion), color var(--motion), transform var(--motion);
}
.board .cube,
.board .cube:hover,
.board .cube:disabled {
  padding: 0;
  opacity: 1;
  cursor: default;
}
.board .cube:hover {
  border-color: var(--border);
}
.board .cube.can-double {
  pointer-events: auto;
  cursor: pointer;
  border-color: var(--accent);
  animation: dice-ready-glow 1.4s ease-in-out infinite;
  box-shadow: var(--shadow), 0 0 0 2px var(--glow-soft), 0 0 14px var(--glow-mid);
}
.board .cube.can-double:hover {
  border-color: var(--accent-hover);
}
.board .cube.owner-white {
  transform: translate(-50%, -90%);
}
.board .cube.owner-black {
  transform: translate(-50%, -10%);
}
.board .cube.offered {
  border-color: var(--accent-hover);
  color: var(--accent-hover);
}
.board .cube-value {
  font-variant-numeric: tabular-nums;
}
.board .board-top .home {
  border-radius: var(--radius-control) var(--radius-control) 0 0;
}
.board .board-bottom .home {
  border-radius: 0 0 var(--radius-control) var(--radius-control);
}
.board .bar.can-move,
.board .home.can-move,
.board .bar.highlight,
.board .home.highlight {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}
.board .bar.valid,
.board .home.valid {
  outline: 2px solid var(--accent-hover);
  outline-offset: -2px;
}
.board .space::before {
  content: '';
  position: absolute;
  z-index: 0;
  left: 10%;
  width: 80%;
  height: 82%;
  pointer-events: none;
}
.board .board-top .space::before {
  top: 0;
  clip-path: polygon(50% 100%, 0 0, 100% 0);
}
.board .board-bottom .space::before {
  bottom: 0;
  clip-path: polygon(50% 0, 0 100%, 100% 100%);
}
.board .point-light::before {
  background: var(--cream);
}
.board .point-dark::before {
  background: var(--walnut);
}
.board .space.can-move::before {
  filter: drop-shadow(0 0 2px var(--accent));
}
.board .space.highlight::before {
  filter: drop-shadow(0 0 2px var(--accent-hover)) drop-shadow(0 0 1px var(--accent));
}
.board .space.valid::before {
  background: var(--accent);
}
.board .bar-cols {
  display: flex;
  justify-content: center;
  align-items: stretch;
  gap: 4px;
  width: 100%;
  height: 100%;
}
.board .space > ul,
.board .bar ul,
.board .home > ul {
  position: relative;
  z-index: 1;
  height: 100%;
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  align-items: center;
}
.board .board-top .space > ul,
.board .board-top .bar ul,
.board .board-top .home > ul {
  flex-direction: column;
  justify-content: flex-start;
}
.board .board-bottom .space > ul,
.board .board-bottom .bar ul,
.board .board-bottom .home > ul {
  flex-direction: column-reverse;
  justify-content: flex-start;
}
.board .bar ul {
  flex: 0 1 var(--piece);
  width: var(--piece);
  min-width: 0;
}
.board .space li,
.board .bar li,
.board .home li {
  display: flex;
  justify-content: center;
  width: 100%;
  flex: 0 1 calc(var(--piece) * 0.82);
  min-height: 0;
  list-style: none;
  z-index: 2;
}
.board .board-top .space li,
.board .board-top .bar li,
.board .board-top .home li {
  align-items: flex-start;
}
.board .board-bottom .space li,
.board .board-bottom .bar li,
.board .board-bottom .home li {
  align-items: flex-end;
}
.board .game-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 12px 0 0;
}
.board .id {
  font-family: Inter, sans-serif;
  font-size: 13px;
  font-weight: 400;
  font-style: normal;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.piece {
  display: block;
  flex: 0 0 auto;
  width: var(--piece, 32px);
  max-width: 100%;
  height: auto;
  aspect-ratio: 1;
  border-radius: 50%;
  box-sizing: border-box;
  transition: transform var(--motion), box-shadow var(--motion);
}
.piece.white {
  background: var(--checker-cream);
  border: 2px solid var(--checker-dark);
}
.piece.black {
  background: var(--checker-dark);
  border: 2px solid var(--accent);
}
.piece.icon {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
}
.highlight li:last-child {
  z-index: 5;
}
.can-move li:last-child .piece,
.highlight li:last-child .piece {
  box-shadow: 0 0 0 2px var(--accent);
}
.highlight li:last-child .piece {
  transform: translateY(-4px);
  box-shadow: 0 0 0 2px var(--accent-hover);
}
@media (max-width: 1100px) {
  .board {
    --half: 200px;
    --bar: 60px;
    --home: 88px;
    --piece: 26px;
  }
  .board .bar-cols {
    gap: 2px;
  }
  .die {
    width: 38px;
    height: 38px;
  }
  .pip {
    width: 5px;
    height: 5px;
  }
  .top-display .player-name {
    max-width: 140px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
  .highlight li:last-child .piece {
    transform: none;
  }
}
@media (max-width: 600px) {
  .title {
    font-size: 22px;
    margin: 12px 0 10px;
  }
  .game-container {
    padding: 0 6px;
  }
  .top-display {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-areas: "banner banner" "status status" "p1 p2" "mid mid";
    gap: 6px 8px;
    margin-bottom: 8px;
    padding: 10px 8px;
    /* Controls in one compact centered row */
  }
  .top-display .status {
    font-size: 13px;
  }
  .top-display .player-one,
  .top-display .player-two {
    padding: 3px 8px;
  }
  .top-display .white,
  .top-display .black {
    font-size: 14px;
  }
  .top-display .player-name {
    max-width: 110px;
  }
  .top-display .mid {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
  }
  .top-display .buttons button {
    min-width: 0;
    padding: 8px 10px;
  }
  .top-display .roll-hint {
    flex-basis: 100%;
  }
  .turn-row {
    gap: 6px;
  }
  .turn-banner {
    font-size: 14px;
    padding: 6px 14px;
    text-align: center;
  }
  .you-badge {
    font-size: 11px;
    padding: 3px 8px;
  }
  .die {
    width: 36px;
    height: 36px;
  }
  .board {
    --pad: 6px;
    --half: clamp(170px, 52vw, 230px);
    --bar: 36px;
    --home: 26px;
    --home-gap: 4px;
    --piece: 22px;
    border-radius: var(--radius-control);
  }
  .board .bar-cols {
    gap: 1px;
  }
  .board .cube {
    width: 30px;
    height: 30px;
    font-size: 13px;
  }
  .board .game-meta {
    margin-top: 8px;
    flex-wrap: wrap;
  }
  .board .id {
    font-size: 11px;
    word-break: break-all;
  }
}
/*# sourceMappingURL=backgammon.1.0.0.css.map */