/*!**************************************************************************************************************************************************************************************************************************************************************************************!*\
  !*** css ./node_modules/next/dist/build/webpack/loaders/css-loader/src/index.js??ruleSet[1].rules[14].oneOf[5].use[2]!./node_modules/next/dist/build/webpack/loaders/postcss-loader/src/index.js??ruleSet[1].rules[14].oneOf[5].use[3]!./app/games/backgammon/backgammon.module.css ***!
  \**************************************************************************************************************************************************************************************************************************************************************************************/
.backgammon_wrapper__wgGXL {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(145deg, #3e2723 0%, #1b0f0a 100%);
  color: white;
  -moz-user-select: none;
       user-select: none;
  -webkit-user-select: none;
  overflow-x: hidden;
  position: relative;
}

/* ── HUD ── */
.backgammon_hud__Xa2mG {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background: rgba(0, 0, 0, 0.3);
  flex-shrink: 0;
  z-index: 10;
  gap: 8px;
}

.backgammon_hudLeft__oq3Lq {
  display: flex;
  gap: 16px;
  align-items: center;
}

.backgammon_statItem__FJcFH {
  text-align: center;
}

.backgammon_statLabel__AX9k8 {
  font-size: 0.55rem;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
  letter-spacing: 0.08em;
}

.backgammon_statValue__JGKE1 {
  font-size: 1.1rem;
  font-weight: 800;
  color: #d4af37;
}

.backgammon_newGameBtn__ClyUM {
  padding: 6px 14px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.backgammon_newGameBtn__ClyUM:hover {
  background: rgba(255, 255, 255, 0.15);
  color: white;
}

/* ── Board ── */
.backgammon_boardContainer__WG3Zw {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 8px;
  min-height: 0;
}

.backgammon_boardOuter__k5u5L {
  width: 100%;
  max-width: 520px;
  background: #5d4037;
  border-radius: 12px;
  padding: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
}

.backgammon_boardRow__KRcVg {
  display: flex;
  min-height: 0;
}

.backgammon_boardHalf__cWheg {
  display: flex;
  flex: 1;
  gap: 1px;
}

.backgammon_bar__j_iTu {
  width: 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #3e2723;
  margin: 0 3px;
  border-radius: 4px;
  gap: 4px;
  flex-shrink: 0;
  padding: 4px 0;
}

.backgammon_barCheckers__fLvEm {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.backgammon_barChecker__Xpxvh {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  flex-shrink: 0;
}

.backgammon_barLabel__0gFUa {
  font-size: 0.5rem;
  color: rgba(255, 255, 255, 0.5);
  font-weight: 700;
}

.backgammon_barClickable__E7jsk {
  cursor: pointer;
}

.backgammon_barSelected__caWBX {
  box-shadow: 0 0 0 2px #d4af37, 0 0 8px rgba(212, 175, 55, 0.6);
}

/* ── Points (triangles) ── */
.backgammon_point__KHjFM {
  flex: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  height: clamp(140px, 28vw, 200px);
  cursor: pointer;
  overflow: visible;
}

.backgammon_pointTop__C0ewO {
  flex-direction: column;
}

.backgammon_pointBottom__wkUjy {
  flex-direction: column-reverse;
}

.backgammon_triangle__rJWcF {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.backgammon_pointTop__C0ewO .backgammon_triangle__rJWcF {
  clip-path: polygon(0% 0%, 100% 0%, 50% 90%);
}

.backgammon_pointBottom__wkUjy .backgammon_triangle__rJWcF {
  clip-path: polygon(50% 10%, 0% 100%, 100% 100%);
}

.backgammon_triangleDark__qycCC {
  background: #8b1a1a;
}

.backgammon_triangleLight__jIiWx {
  background: #d4a574;
}

.backgammon_pointSelected__9hzcd .backgammon_triangle__rJWcF {
  outline: 2px solid #d4af37;
  outline-offset: -1px;
}

.backgammon_pointValidDest__BfP_J::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 24px;
  height: 24px;
  background: rgba(212, 175, 55, 0.5);
  border-radius: 50%;
  z-index: 5;
  pointer-events: none;
}

/* ── Checkers ── */
.backgammon_checkerStack__N51dc {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 2;
  width: 100%;
}

.backgammon_pointTop__C0ewO .backgammon_checkerStack__N51dc {
  flex-direction: column;
}

.backgammon_pointBottom__wkUjy .backgammon_checkerStack__N51dc {
  flex-direction: column-reverse;
}

.backgammon_checker__ld_KN {
  width: clamp(22px, 5.5vw, 34px);
  height: clamp(22px, 5.5vw, 34px);
  border-radius: 50%;
  flex-shrink: 0;
  position: relative;
}

.backgammon_checkerWhite__48ebl {
  background: linear-gradient(145deg, #faf5ed, #e8dcc8);
  box-shadow: inset -2px -2px 6px rgba(0, 0, 0, 0.15),
    inset 2px 2px 6px rgba(255, 255, 255, 0.5),
    0 2px 4px rgba(0, 0, 0, 0.3);
}

.backgammon_checkerBlack___5EMJ {
  background: linear-gradient(145deg, #3a3a3a, #1a1a1a);
  box-shadow: inset -2px -2px 6px rgba(0, 0, 0, 0.5),
    inset 2px 2px 6px rgba(255, 255, 255, 0.08),
    0 2px 4px rgba(0, 0, 0, 0.4);
}

.backgammon_checkerCount__XNnCA {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 0.6rem;
  font-weight: 800;
  color: white;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
  z-index: 3;
}

.backgammon_checkerCountBlack__NwHcZ {
  color: rgba(255, 255, 255, 0.9);
}

.backgammon_checkerCountWhite__nutdq {
  color: rgba(0, 0, 0, 0.7);
  text-shadow: none;
}

/* ── Bear-off tray ── */
.backgammon_bearOffTray__EPG7J {
  position: absolute;
  right: -44px;
  top: 0;
  bottom: 0;
  width: 38px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
}

.backgammon_bearOffSection__zqkJ6 {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
}

.backgammon_bearOffChip__6hblL {
  width: 28px;
  height: 6px;
  border-radius: 2px;
}

.backgammon_bearOffChipWhite__lUUSp {
  background: #e8dcc8;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.backgammon_bearOffChipBlack__Fz3DV {
  background: #2c2c2c;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.backgammon_bearOffLabel__V_phg {
  font-size: 0.5rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 2px;
}

.backgammon_bearOffValidDest__bdxZf {
  cursor: pointer;
  box-shadow: 0 0 0 2px #d4af37, 0 0 8px rgba(212, 175, 55, 0.6);
  border-radius: 4px;
  padding: 2px;
}

/* ── Dice area ── */
.backgammon_diceArea__K8QiC {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 10px 0;
  flex-shrink: 0;
}

.backgammon_die__ZWU7J {
  width: 44px;
  height: 44px;
  background: #f5f0e8;
  border-radius: 8px;
  position: relative;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  flex-shrink: 0;
}

.backgammon_dieUsed__7Pvmp {
  opacity: 0.25;
}

.backgammon_pip__TBFnA {
  position: absolute;
  width: 20%;
  height: 20%;
  background: #1a1a1a;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.backgammon_rollBtn__Di5c6 {
  padding: 10px 28px;
  border-radius: 10px;
  border: none;
  background: linear-gradient(145deg, #c0392b, #8b1a1a);
  color: white;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
  box-shadow: 0 3px 10px rgba(192, 57, 43, 0.4);
}

.backgammon_rollBtn__Di5c6:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 5px 16px rgba(192, 57, 43, 0.6);
}

.backgammon_rollBtn__Di5c6:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
}

/* ── Phase indicator ── */
.backgammon_phaseIndicator__lz6z9 {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  text-align: center;
  padding: 2px 0;
}

/* ── Message ── */
.backgammon_message__5Z5Mg {
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: 8px;
  padding: 6px 16px;
  font-size: 0.8rem;
  color: #d4af37;
  font-weight: 600;
  text-align: center;
}

/* ── Overlay ── */
.backgammon_overlay__2HRd_ {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 50;
  gap: 12px;
  animation: backgammon_fadeIn__7lXE3 0.3s ease-out;
  padding: 16px;
}

@keyframes backgammon_fadeIn__7lXE3 {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.backgammon_overlayTitle__QUtwF {
  font-size: 1.8rem;
  font-weight: 900;
  color: #d4af37;
  text-shadow: 0 0 20px rgba(212, 175, 55, 0.4);
}

.backgammon_overlaySubtitle__45B7L {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.6);
  text-align: center;
}

.backgammon_overlayBtn__zrZRe {
  margin-top: 8px;
  padding: 12px 32px;
  border-radius: 10px;
  border: none;
  background: linear-gradient(145deg, #d4af37, #b8960c);
  color: #1a1a2e;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}

.backgammon_overlayBtn__zrZRe:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(212, 175, 55, 0.4);
}

/* ── Point numbers ── */
.backgammon_pointNumber__NZBqs {
  font-size: 0.45rem;
  color: rgba(255, 255, 255, 0.3);
  font-weight: 700;
  position: absolute;
  z-index: 1;
}

.backgammon_pointTop__C0ewO .backgammon_pointNumber__NZBqs {
  top: -12px;
}

.backgammon_pointBottom__wkUjy .backgammon_pointNumber__NZBqs {
  bottom: -12px;
}

/* ── Responsive ── */
@media (max-width: 520px) {
  .backgammon_bearOffTray__EPG7J {
    position: static;
    flex-direction: row;
    width: 100%;
    padding: 4px 8px;
    gap: 12px;
    justify-content: center;
  }

  .backgammon_bearOffSection__zqkJ6 {
    flex-direction: row;
    gap: 2px;
  }

  .backgammon_bearOffChip__6hblL {
    width: 6px;
    height: 20px;
  }
}

@media (max-width: 480px) {
  .backgammon_hud__Xa2mG {
    padding: 6px 8px;
  }

  .backgammon_statValue__JGKE1 {
    font-size: 0.95rem;
  }

  .backgammon_point__KHjFM {
    height: clamp(110px, 24vw, 160px);
  }

  .backgammon_die__ZWU7J {
    width: 38px;
    height: 38px;
  }

  .backgammon_bar__j_iTu {
    width: 28px;
  }

  .backgammon_barChecker__Xpxvh {
    width: 20px;
    height: 20px;
  }
}

@media (max-width: 360px) {
  .backgammon_point__KHjFM {
    height: clamp(90px, 20vw, 130px);
  }

  .backgammon_die__ZWU7J {
    width: 34px;
    height: 34px;
  }

  .backgammon_checker__ld_KN {
    width: clamp(18px, 5vw, 28px);
    height: clamp(18px, 5vw, 28px);
  }
}

