  * { margin: 0; padding: 0; box-sizing: border-box; border-radius: 0 !important; }

  :root {
    --win-blue: #245edb;
    --light-sq: #b0b0b0;
    --dark-sq: #3a3a3a;
    --border: #333;
  }

  body {
    background: #000;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    min-height: 100vh;
    padding: 0;
    margin: 0;
    font-family: 'Tahoma', sans-serif;
  }

  #wrap {
    display: inline-flex;
    flex-direction: column;
    border: 1px solid var(--border);
  }

  #board {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    grid-template-rows: repeat(8, 1fr);
    width: 100vmin;
    height: 100vmin;
    max-width: 600px;
    max-height: 600px;
  }

  .square {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
  }

  .light { background: var(--light-sq); }
  .dark  { background: var(--dark-sq); }
  .selected { background: rgba(36,94,219,0.55) !important; outline: 2px solid var(--win-blue); }

  .possible::after {
    content: '';
    position: absolute;
    width: 32%; height: 32%;
    background: #0f0;
    opacity: 0.8;
    border-radius: 50% !important;
    pointer-events: none;
  }
  .possible-cap { outline: 2px solid #f44 !important; }

  .piece {
    font-size: min(42px, 11vmin);
    user-select: none;
    filter: drop-shadow(1px 1px 1px rgba(0,0,0,0.6));
    line-height: 1;
  }

  .checker {
    width: 78%; height: 78%;
    border-radius: 50% !important;
    border: 2px solid rgba(0,0,0,0.45);
    box-shadow: 2px 2px 5px rgba(0,0,0,0.6);
    display: flex; align-items: center; justify-content: center;
    font-size: min(15px, 3.5vmin); font-weight: bold;
  }
  .checker.white { background: radial-gradient(circle at 30% 30%, #fff, #999); color: #555; }
  .checker.black { background: radial-gradient(circle at 30% 30%, #555, #111); color: #ccc; }
  .checker.king  { border: 3px double var(--win-blue); }

  #bar {
    background: #111;
    border-top: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 4px 8px;
    gap: 8px;
    font-size: 10px;
    color: #aaa;
    font-family: 'Tahoma', monospace;
    min-height: 26px;
  }

  #status {
    font-weight: bold;
    font-size: 11px;
    letter-spacing: 1px;
    min-width: 110px;
  }
  
  @keyframes capture-fade {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.4); opacity: 0.7; filter: brightness(2); }
    100% { transform: scale(0); opacity: 0; }
  }

  .capturing {
    animation: capture-fade 0.4s ease-out forwards;
    pointer-events: none;
    z-index: 10;
  }

  .piece, .checker {
    transition: all 0.2s ease-out;
  }

  #info { color: #555; flex: 1; text-align: center; font-size: 9px; }

  #bar-right { display: flex; align-items: center; gap: 6px; }

  select {
    background: #000; color: #aaa;
    border: 1px solid var(--border);
    font-size: 9px; padding: 1px 2px;
    font-family: 'Tahoma', monospace;
  }

  button {
    background: linear-gradient(to bottom, #2a2a2a, #111);
    border: 1px solid var(--border);
    color: #aaa;
    padding: 2px 8px;
    cursor: pointer;
    font-size: 9px;
    font-family: 'Tahoma', monospace;
  }
  button:hover { border-color: var(--win-blue); color: #fff; }
