/* 1) Base button reset */
.color-swatch-button {
  border: none;
  background: none;
  padding: 4px;
  margin: 0 6px 6px 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  flex-direction: column;
  font-family: sans-serif;
  font-size: 12px;
  color: #333;
  text-align: center;
}
@media (max-width: 600px) {
  .color-swatch-button {
    padding: 6px;
    margin: 0 8px 8px 0;
  }
}

/* 2) Swatch as square, use box-sizing so border/padding don't shift size */
.color-swatch-button .swatch-circle {
  display: inline-block;
  width: 26px;
  height: 26px;
  border-radius: 0;      /* square */
  border: none;          /* no border when not active */
  box-shadow: 0 0 2px rgba(0,0,0,0.1);
  margin-bottom: 4px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  box-sizing: border-box;
  background-clip: content-box;
  -webkit-background-clip: content-box; /* Safari */
}
/* mobile size */
@media (max-width: 600px) {
  .color-swatch-button .swatch-circle {
    width: 32px;
    height: 32px;
  }
}

/* 3) Hover: enlarge + stronger shadow */
.color-swatch-button:hover .swatch-circle {
  transform: scale(1.1);
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* 4A) Active state using outline (does not affect layout) */
.color-swatch-button.active .swatch-circle {
  outline: 2px solid #000;
  outline-offset: 2px; /* space between swatch and outline */
  /* keep same box-shadow or adjust */
  box-shadow: 0 0 4px rgba(0,0,0,0.3);
}

/* Alternative 4B) Active state using box-shadow for border effect:
   (uncomment if you prefer this over outline) */


/* 5) Label under each square */
.color-swatch-button .swatch-label {
  display: block;
  white-space: nowrap;
  text-transform: capitalize;
}
